Skip to content

Commit cf9b3b2

Browse files
committed
MDEV-23608 : galera_sr.GCF-597 MTR failed: query 'ROLLBACK' succeeded - should have failed with errno 1213
Added wait_condition to wait correct streaming state.
1 parent 44e7e1f commit cf9b3b2

File tree

2 files changed

+20
-1
lines changed

2 files changed

+20
-1
lines changed

mysql-test/suite/galera_sr/r/GCF-597.result

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,13 @@ INSERT INTO t1 VALUES (2);
1515
INSERT INTO t1 VALUES (3);
1616
INSERT INTO t1 VALUES (4);
1717
INSERT INTO t1 VALUES (5);
18+
connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1;
19+
connection node_1a;
20+
connect node_2a, 127.0.0.1, root, , test, $NODE_MYPORT_2;
21+
connection node_2a;
1822
connection node_2;
1923
ROLLBACK;
2024
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
2125
DROP TABLE t1;
26+
disconnect node_1a;
27+
disconnect node_2a;

mysql-test/suite/galera_sr/t/GCF-597.test

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,21 @@ INSERT INTO t1 VALUES (3);
2222
INSERT INTO t1 VALUES (4);
2323
INSERT INTO t1 VALUES (5);
2424

25+
--connect node_1a, 127.0.0.1, root, , test, $NODE_MYPORT_1
26+
--connection node_1a
27+
--let $wait_condition = SELECT COUNT(*) = 5 FROM mysql.wsrep_streaming_log
28+
--source include/wait_condition.inc
29+
30+
--connect node_2a, 127.0.0.1, root, , test, $NODE_MYPORT_2
31+
--connection node_2a
32+
--let $wait_condition = SELECT COUNT(*) = 5 FROM mysql.wsrep_streaming_log
33+
--source include/wait_condition.inc
34+
2535
--connection node_2
2636
--error ER_LOCK_DEADLOCK
2737
ROLLBACK;
2838

29-
DROP TABLE t1;
39+
DROP TABLE t1;
40+
41+
--disconnect node_1a
42+
--disconnect node_2a

0 commit comments

Comments
 (0)