TiCDC sends all data to the same partition in Kafka

This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: ticdc发送到kafka的数据全部写到同一个分区内

| username: TiDBer_wmWYn7Oo

cdc startup configuration

tiup cdc cli changefeed --pd=,, create --sink-uri=“kafka://,,,,” --changefeed-id=“cdctmswaybill” --config cdc_dwd_tms_waybill_incream_cdc.toml

| username: WalterWj | Original post link

Specify the partition-num parameter in the sink-uri, for example: <kafka://localhost:9092/test?partition-num=3> and give it a try.

| username: TiDBer_wmWYn7Oo | Original post link

I see that the official documentation states that this parameter specifies the number of partitions for the downstream Kafka. We have configured it to be consistent with the number of downstream partitions, partition-num=5. Is there any reason for your suggestion to change it to the default configuration, partition-num=3?

| username: redgame | Original post link

It looks like it was written according to your requirements.