Configuring control topics
Configure names and configuration of control topics.
To execute K2K, you must agree to the EULA and secure a free license.
Accept the EULA by setting license.acceptEula to true .
In a K2K setup, up to three topics are required for state coordination and progress tracking, depending on the feature used. See Coordination and Assignment for details.
Environment with all three topics
Utilize these files to initiate an replication instance exercising all three control topics.
name: "my-first-replication"
features:
autoCreateControlTopics: enabled
autoCreateTopics: enabled
exactlyOnce: enabled
source:
kafka:
common:
"bootstrap.servers": "kafka-source:9092"
consumer:
"group.id": "k2k.my-first-k2k"
target:
kafka:
common:
"bootstrap.servers": "kafka-target:9092"
replication:
- source:
topic: ".*"
- sink:
topic: source
partition: sourceCustomizing control topic names
To customize control topic names in the K2K application, modify these configuration properties:
coordination.kafka.commit.topiccoordination.kafka.assignement.topicmetrics.kafka.topic
Customizing configurations
Enable auto-creation to ensure K2K creates control topics only if they are missing. To prevent interference from previous steps, execute:
Specify the properties of control topics as indicated:
For each control topic, the final configuration is created by merging the common configuration section with the specific section for that topic.
By default, assignments and commits are created as compacted topics. Modifying the cleanup policy might cause K2K to fail at startup. Although you can disable control topic validation using features.validateControlTopicSettings, it is not advisable. Using non-compacted topics can degrade performance.
Last updated
Was this helpful?

