Skip to content

Commit a4b6409

Browse files
committed
sporadic failures of binlog_encryption.rpl_parallel_slave_bgc_kill
do CHANGE MASTER before sync_with_master to have the slave in a predictable fully synced state before the next test
1 parent c7c3967 commit a4b6409

File tree

3 files changed

+9
-17
lines changed

3 files changed

+9
-17
lines changed

mysql-test/suite/binlog_encryption/rpl_parallel_slave_bgc_kill.result

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -206,10 +206,12 @@ RETURN x;
206206
END
207207
||
208208
SET sql_log_bin=1;
209+
include/stop_slave_io.inc
209210
connection server_1;
210211
INSERT INTO t3 VALUES (49,0);
211212
connection server_2;
212-
START SLAVE SQL_THREAD;
213+
CHANGE MASTER TO master_use_gtid=no;
214+
include/start_slave.inc
213215
SELECT * FROM t3 WHERE a >= 40 ORDER BY a;
214216
a b
215217
41 41
@@ -239,10 +241,6 @@ SET GLOBAL slave_parallel_threads=0;
239241
SET GLOBAL slave_parallel_threads=10;
240242
include/start_slave.inc
241243
*** 3. Same as (2), but not using gtid mode ***
242-
connection server_2;
243-
include/stop_slave.inc
244-
CHANGE MASTER TO master_use_gtid=no;
245-
include/start_slave.inc
246244
connection server_1;
247245
connection con_temp3;
248246
SET debug_sync='commit_after_release_LOCK_prepare_ordered SIGNAL master_queued1 WAIT_FOR master_cont1';

mysql-test/suite/rpl/r/rpl_parallel_slave_bgc_kill.result

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -206,10 +206,12 @@ RETURN x;
206206
END
207207
||
208208
SET sql_log_bin=1;
209+
include/stop_slave_io.inc
209210
connection server_1;
210211
INSERT INTO t3 VALUES (49,0);
211212
connection server_2;
212-
START SLAVE SQL_THREAD;
213+
CHANGE MASTER TO master_use_gtid=no;
214+
include/start_slave.inc
213215
SELECT * FROM t3 WHERE a >= 40 ORDER BY a;
214216
a b
215217
41 41
@@ -239,10 +241,6 @@ SET GLOBAL slave_parallel_threads=0;
239241
SET GLOBAL slave_parallel_threads=10;
240242
include/start_slave.inc
241243
*** 3. Same as (2), but not using gtid mode ***
242-
connection server_2;
243-
include/stop_slave.inc
244-
CHANGE MASTER TO master_use_gtid=no;
245-
include/start_slave.inc
246244
connection server_1;
247245
connection con_temp3;
248246
SET debug_sync='commit_after_release_LOCK_prepare_ordered SIGNAL master_queued1 WAIT_FOR master_cont1';

mysql-test/suite/rpl/t/rpl_parallel_slave_bgc_kill.test

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -295,13 +295,14 @@ CREATE FUNCTION foo(x INT, d1 VARCHAR(500), d2 VARCHAR(500))
295295
||
296296
--delimiter ;
297297
SET sql_log_bin=1;
298-
298+
--source include/stop_slave_io.inc
299299
--connection server_1
300300
INSERT INTO t3 VALUES (49,0);
301301
--save_master_pos
302302

303303
--connection server_2
304-
START SLAVE SQL_THREAD;
304+
CHANGE MASTER TO master_use_gtid=no;
305+
--source include/start_slave.inc
305306
--sync_with_master
306307
SELECT * FROM t3 WHERE a >= 40 ORDER BY a;
307308
# Restore the foo() function.
@@ -334,11 +335,6 @@ SET GLOBAL slave_parallel_threads=10;
334335

335336
--echo *** 3. Same as (2), but not using gtid mode ***
336337

337-
--connection server_2
338-
--source include/stop_slave.inc
339-
CHANGE MASTER TO master_use_gtid=no;
340-
--source include/start_slave.inc
341-
342338
--connection server_1
343339
# Set up three transactions on the master that will be group-committed
344340
# together so they can be replicated in parallel on the slave.

0 commit comments

Comments
 (0)