Commit 748e8a35 authored by unknown's avatar unknown

Fix sporadic failure of test rpl.rpl_gtid_startpos

The test did RESET MASTER and then tried to use --sync_with_master
to wait for GTID-based replication to catch up. This though has
a race, there is a small window where the _old_ pre-RESET MASTER
position on the slave is higher than the new pos-RESET MASTER
position, causing the --sync_with_master to be a no-op.

Fix by using include/wait_condition.inc instead.
parent df66ee7f
......@@ -249,11 +249,11 @@ SET GLOBAL gtid_slave_pos="";
RESET MASTER;
TRUNCATE TABLE t1;
INSERT INTO t1 VALUES (10); # Will be GTID 0-1-2
--save_master_pos
--connection server_2
--source include/start_slave.inc
--sync_with_master
--let $wait_condition= SELECT COUNT(*) = 1 FROM t1
--source include/wait_condition.inc
SELECT * FROM t1;
--let $value= query_get_value(SHOW SLAVE STATUS, "Using_Gtid", 1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment