flink版本1.20.0,doris版本3.0.3
/etc/docker/flink-1.20.0/bin/flink run
-Dexecution.checkpointing.interval=10s
-Dparallelism.default=1
-c org.apache.doris.flink.tools.cdc.CdcTools
/etc/docker/flink-1.20.0/lib/flink-doris-connector-1.20-24.1.0.jar
mysql-sync-database
--database jsy_finance
--job-name vc_voucher
--mysql-conf hostname=192.168.200.81
--mysql-conf port=3306
--mysql-conf username=root
--mysql-conf password=root
--mysql-conf database-name=doristtest
--mysql-conf server-time-zone=Asia/Shanghai
--including-tables "vc_voucher"
--sink-conf fenodes=192.168.200.125:8030
--sink-conf username=root
--sink-conf password=root
--sink-conf jdbc-url=jdbc:mysql://192.168.200.125:9030
--sink-conf sink.label-prefix=label
--sink-conf primary-key=id,accounting_period
--sink-conf upsert=true
--table-conf replication_num=1
数据同步后出现id重复的记录,我可以100%确定vc_voucher表中id和accounting_period的组合是唯一的,flink版本1.20.0,doris版本3.0.3