-
Notifications
You must be signed in to change notification settings - Fork 7.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
自定义规则,只有一个topic,一个表对应一个分区,kafka #5347
Comments
代码已经写完啦,也进行测试了,有人需要吗 |
地址发下,学习一下 |
替换com.alibaba.otter.canal.connector.kafka.producer.CanalKafkaProducer文件就好 package com.alibaba.otter.canal.connector.kafka.producer; import java.io.File; import com.alibaba.otter.canal.common.utils.PropertiesUtils; import com.alibaba.fastjson2.JSON; /**
// System.out.println(entry.getHeader());
} |
只要打包一下,然后将connector.kafka-1.1.7-jar-with-dependencies.jar替换到\canal.deployer-1.1.7\plugin下面就行 |
可以考虑提交一个PR给我 |
#5359 提交了 |
Why you need it?
业务需求,只有一个topic,一个表对应一个分区
How it could be?
Other related information
canal.mq.dynamicTopic=self|test_db.test_table2:1,test_db.test_table1:2,test_db.test_table:3
解析dynamicTopic,如果是self|打头,就执行自定义的规则
test_db.test_table2的数据变动同步到topic的分区1
test_db.test_table1的数据变动同步到topic的分区2
The text was updated successfully, but these errors were encountered: