cdc: EXCHANGE PARTITION dropped the WITHOUT VALIDATION clause #10859
Closed
Description
What did you do?
create a TiDB → TiCDC → TiDB changefeed and execute the following in upstream:
USE test;
CREATE TABLE employees (
id INT NOT NULL ,
store_id INT NOT NULL primary key
) PARTITION BY RANGE (store_id) (
PARTITION p0 VALUES LESS THAN (6),
PARTITION p1 VALUES LESS THAN (11),
PARTITION p2 VALUES LESS THAN (16),
PARTITION p3 VALUES LESS THAN (21)
);
CREATE TABLE employees_temp (
id INT NOT NULL ,
store_id INT NOT NULL primary key
);
insert into employees values(1,1);
insert into employees values(8,8);
insert into employees_temp values(16,8);
insert into employees_temp values(17,17);
ALTER TABLE employees EXCHANGE PARTITION p0 WITH TABLE employees_temp without VALIDATION;
What did you expect to see?
The DDL is sync to the downstream TiDB correctly.
What did you see instead?
The changefeed is stuck. TiCDC has rewritten the DDL which stripped out the WITHOUT VALIDATION
option
ALTER TABLE `test`.`employees` EXCHANGE PARTITION `p0` WITH TABLE `test`.`employees_temp`
which caused the [ddl:1737]Found a row that does not match the partition
unretryable error
Versions of the cluster
Upstream TiDB cluster version (execute SELECT tidb_version();
in a MySQL client):
v6.5.8
Upstream TiKV version (execute tikv-server --version
):
v6.5.8
TiCDC version (execute cdc version
):
v6.5.8
Metadata
Assignees
Labels
Type
Projects
Status
Done