Commit e4d7886c authored by Andrei's avatar Andrei

MDEV-11675. rpl_start_alter_ftwrl.test is refined

The test could fail sporadically because of not anticipated
race on slave between CREATE and ALTER queries.

Fixed to synchronize slave and master wrt CREATE.
parent 12f29a4b
......@@ -10,6 +10,10 @@ include/start_slave.inc
connection master;
SET @@session.binlog_alter_two_phase=true;
CREATE TABLE t1 (a INT) ENGINE=innodb;
include/save_master_gtid.inc
connection slave;
include/sync_with_master_gtid.inc
connection master;
SET @@session.alter_algorithm='INSTANT';
SET @@session.gtid_domain_id=11;
ALTER TABLE t1 ADD COLUMN b int;
......
......@@ -26,7 +26,13 @@ SET @@global.debug_dbug="+d,at_write_start_alter";
SET @@session.binlog_alter_two_phase=true;
CREATE TABLE t1 (a INT) ENGINE=innodb;
--source include/save_master_gtid.inc
# Make sure the table exists on slave now.
--connection slave
--source include/sync_with_master_gtid.inc
--connection master
SET @@session.alter_algorithm='INSTANT';
SET @@session.gtid_domain_id=11;
ALTER TABLE t1 ADD COLUMN b int;
......
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