| 1 |
# ==== Purpose ==== |
| 2 |
# The test considers scenarios of OLD -> NEW replication, where NEW stands |
| 3 |
# for WL9175-based slave server, and OLD is of a prior version master. |
| 4 |
# This file consists of cases that need GTID=OFF. |
| 5 |
# |
| 6 |
# ==== References ==== |
| 7 |
# WL#9175 Correct recovery of DDL statements/transactions by binary log |
| 8 |
# Bug #25665464 CROSS VERSION RPL BEHAVES DIFFERENTLY VARYING RELAY LOG INFO REPOSITORY CONF |
| 9 |
# |
| 10 |
|
| 11 |
--source include/have_log_bin.inc |
| 12 |
--source include/have_debug.inc |
| 13 |
--source include/have_binlog_format_row.inc |
| 14 |
|
| 15 |
# |
| 16 |
# It's proved that the slave applier stops with an expected error |
| 17 |
# of mismatch between one that is recorded on master and the actual. |
| 18 |
# The slave applier does not update the execution coordinates so |
| 19 |
# at retry when the error simulation is withdrawn the event must |
| 20 |
# complete to good. |
| 21 |
# |
| 22 |
|
| 23 |
--source include/master-slave.inc |
| 24 |
|
| 25 |
--source include/rpl_connection_master.inc |
| 26 |
--disable_warnings |
| 27 |
DROP TABLE IF EXISTS t1; |
| 28 |
--enable_warnings |
| 29 |
|
| 30 |
--source include/sync_slave_sql_with_master.inc |
| 31 |
# --source include/rpl_connection_slave.inc |
| 32 |
call mtr.add_suppression("The replica coordinator and worker threads are stopped"); |
| 33 |
call mtr.add_suppression("Query caused different errors on source and replica"); |
| 34 |
|
| 35 |
SET @@global.debug="+d,simulate_error_in_ddl"; |
| 36 |
|
| 37 |
--source include/rpl_connection_master.inc |
| 38 |
CREATE TABLE t1(a int); |
| 39 |
|
| 40 |
--source include/rpl_connection_slave.inc |
| 41 |
|
| 42 |
--let $slave_sql_errno= convert_error(ER_INCONSISTENT_ERROR) |
| 43 |
--source include/wait_for_slave_sql_error.inc |
| 44 |
|
| 45 |
# Now the slave is inconsistent as if a non-atomic DDL has failed on it. |
| 46 |
# The table has to be dropped in order to proceed from the error. |
| 47 |
DROP TABLE t1; |
| 48 |
SET @@global.debug="-d,simulate_error_in_ddl"; |
| 49 |
--source include/start_slave_sql.inc |
| 50 |
|
| 51 |
# Cleanup |
| 52 |
--source include/rpl_connection_master.inc |
| 53 |
DROP TABLE t1; |
| 54 |
|
| 55 |
--source include/rpl_end.inc |