public class BrokerDefaultConfigChangeEvent extends MetadataCollectorEvent
LocalStore
, and emit incremental events for each
individual topic.
The below broker default config changes will propagate to existing topics:
* log.retention.ms
* log.retention.bytes
* log.cleanup.policyCACHE_BUILD_EVENT_TAG, SNAPSHOT_EVENT_TAG
Constructor and Description |
---|
BrokerDefaultConfigChangeEvent(ZKMetadataCollector collector,
kafka.server.KafkaConfig oldConfig,
kafka.server.KafkaConfig newConfig,
org.apache.kafka.common.utils.Time time) |
Modifier and Type | Method and Description |
---|---|
static boolean |
hasCatalogInterestedChange(kafka.server.KafkaConfig oldConfig,
kafka.server.KafkaConfig newConfig)
Given the old KafkaConfig and new KafkaConfig, return a map of configs that has change and
their new value.
|
static boolean |
propagateBrokerConfigChange(ZKMetadataCollectorContext context,
kafka.server.KafkaConfig oldConfig,
kafka.server.KafkaConfig newConfig,
String topic,
io.confluent.protobuf.events.catalog.v1.TopicMetadata.Builder builder)
Propagate broker config change to a topic.
|
void |
run() |
String |
toString() |
handleException
public BrokerDefaultConfigChangeEvent(ZKMetadataCollector collector, kafka.server.KafkaConfig oldConfig, kafka.server.KafkaConfig newConfig, org.apache.kafka.common.utils.Time time)
public static boolean propagateBrokerConfigChange(ZKMetadataCollectorContext context, kafka.server.KafkaConfig oldConfig, kafka.server.KafkaConfig newConfig, String topic, io.confluent.protobuf.events.catalog.v1.TopicMetadata.Builder builder)
context
- the Collector contextoldConfig
- the old KafkaConfignewConfig
- the new KafkaConfigtopic
- topic name with tenant prefixbuilder
- the TopicMetadata builder for this topictrue
if it should propagate any of the broker config changes to this topic,
false
otherwisepublic static boolean hasCatalogInterestedChange(kafka.server.KafkaConfig oldConfig, kafka.server.KafkaConfig newConfig)
oldConfig
- the old KafkaConfignewConfig
- the new KafkaConfig