summaryrefslogtreecommitdiff
path: root/sql/rpl_mi.cc
diff options
context:
space:
mode:
authorMonty <monty@mariadb.org>2016-01-03 13:27:59 +0200
committerMonty <monty@mariadb.org>2016-01-03 13:27:59 +0200
commit8fcc0bfefadcb4e9f7acb13d11661daeea5097f9 (patch)
tree4863ff0cd610e325e29ce48cfa36dc954c8d046f /sql/rpl_mi.cc
parent661a6d89065390ca1e9b4be05219b75f850ed290 (diff)
downloadmariadb-git-8fcc0bfefadcb4e9f7acb13d11661daeea5097f9.tar.gz
Fixed bug in semi_sync replication tests.
The problem was that wait_for_slave_io_to_start reported that the io thread was ready, when it was still initializing. This caused test suite to continue too early, for example before the semi sync plugin was properly enabled. Fixed by introducing a new internal stage: "Preparing". Slave_IO_Running is now set to "Yes" only when all initializing is done and the IO thread is ready to read things from the master. The only test affected by this change is rpl_flsh_tbls, which got stuck in the preparing phase while trying to read the GTID position from a table. Fixed by having this test waiting for Preparing instead of Yes.
Diffstat (limited to 'sql/rpl_mi.cc')
-rw-r--r--sql/rpl_mi.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/rpl_mi.cc b/sql/rpl_mi.cc
index a7ee3f3f45e..9c6f4639717 100644
--- a/sql/rpl_mi.cc
+++ b/sql/rpl_mi.cc
@@ -1321,7 +1321,7 @@ bool Master_info_index::start_all_slaves(THD *thd)
Try to start all slaves that are configured (host is defined)
and are not already running
*/
- if ((mi->slave_running != MYSQL_SLAVE_RUN_CONNECT ||
+ if ((mi->slave_running == MYSQL_SLAVE_NOT_RUN ||
!mi->rli.slave_running) && *mi->host)
{
if ((error= start_slave(thd, mi, 1)))