diff options
author | Sven Sandberg <sven@mysql.com> | 2008-07-23 13:23:52 +0200 |
---|---|---|
committer | Sven Sandberg <sven@mysql.com> | 2008-07-23 13:23:52 +0200 |
commit | ef47cbd41599115856010e6f5f117c53581d4136 (patch) | |
tree | caba3b5ef920ee49efc146c30aa3923cac0d48d2 /mysql-test/include/wait_for_slave_io_to_start.inc | |
parent | 47f6bc83827a38260345e0536f4ee47ecddb93dd (diff) | |
download | mariadb-git-ef47cbd41599115856010e6f5f117c53581d4136.tar.gz |
BUG#37717: rpl.rpl_stm_until 'stmt' fails sporadically on pushbuild
Problem: After START SLAVE, the Slave_IO_Status column of
SHOW SLAVE STATUS goes from No to Yes asynchronously. That
caused sporadic failures on pushbuild in rpl_stm_until since
the test contains SHOW SLAVE STATUS right after START SLAVE.
Fix: Wait until Slave_IO_Status becomes Yes after each
START SLAVE.
mysql-test/include/wait_for_slave_io_to_start.inc:
Macro that waits until the Slave_IO_Running field of
SHOW SLAVE STATUS becomes Yes.
mysql-test/suite/rpl/r/rpl_stm_until.result:
updated result file
mysql-test/suite/rpl/t/rpl_stm_until.test:
- Added wait_for_slave_io_to_start after each start slave.
- Removed unused initialization of test variable $VERSION
- Added comments.
Diffstat (limited to 'mysql-test/include/wait_for_slave_io_to_start.inc')
-rw-r--r-- | mysql-test/include/wait_for_slave_io_to_start.inc | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/mysql-test/include/wait_for_slave_io_to_start.inc b/mysql-test/include/wait_for_slave_io_to_start.inc new file mode 100644 index 00000000000..3ada2a0e927 --- /dev/null +++ b/mysql-test/include/wait_for_slave_io_to_start.inc @@ -0,0 +1,19 @@ +# ==== Purpose ==== +# +# Waits until the IO thread of the current connection has started and +# connected to the master (i.e., until SHOW SLAVE STATUS returns Yes +# in the Slave_IO_Running field), or until a timeout is reached. +# +# ==== Usage ==== +# +# source include/wait_for_slave_io_to_start.inc; +# +# Parameters to this macro are $slave_timeout and +# $slave_keep_connection. See wait_for_slave_param.inc for +# descriptions. + +let $slave_param= Slave_IO_Running; +let $slave_param_value= Yes; +let $slave_error_message= Failed while waiting for slave IO thread to start; +source include/wait_for_slave_param.inc; +let $slave_error_message= ; |