diff --git a/mysql-test/suite/rpl/t/rpl_parallel_sbm.test b/mysql-test/suite/rpl/t/rpl_parallel_sbm.test index 9c502ff6cb9..3bf39b47f69 100644 --- a/mysql-test/suite/rpl/t/rpl_parallel_sbm.test +++ b/mysql-test/suite/rpl/t/rpl_parallel_sbm.test @@ -1,9 +1,9 @@ # # Ensure that Seconds_Behind_Master works correctly on the parallel replica. # ---source include/master-slave.inc --source include/have_log_bin.inc --source include/have_debug.inc +--source include/master-slave.inc --echo # --echo # MDEV-29639: Seconds_Behind_Master is incorrect for Delayed, Parallel Replicas diff --git a/sql/rpl_rli.cc b/sql/rpl_rli.cc index 4352cdcf494..efcbd29ef39 100644 --- a/sql/rpl_rli.cc +++ b/sql/rpl_rli.cc @@ -44,8 +44,6 @@ rpl_slave_state *rpl_global_gtid_slave_state; /* Object used for MASTER_GTID_WAIT(). */ gtid_waiting rpl_global_gtid_waiting; -const char *const Relay_log_info::state_delaying_string = "Waiting until MASTER_DELAY seconds after master executed event"; - Relay_log_info::Relay_log_info(bool is_slave_recovery, const char* thread_name) :Slave_reporting_capability(thread_name), replicate_same_server_id(::replicate_same_server_id), diff --git a/sql/rpl_rli.h b/sql/rpl_rli.h index 46eacf3411a..ec93f76432b 100644 --- a/sql/rpl_rli.h +++ b/sql/rpl_rli.h @@ -506,11 +506,6 @@ public: m_flags&= ~flag; } - /** - Text used in THD::proc_info when the slave SQL thread is delaying. - */ - static const char *const state_delaying_string; - bool flush(); /** @@ -533,7 +528,7 @@ public: { mysql_mutex_assert_owner(&data_lock); sql_delay_end= delay_end; - thd_proc_info(sql_driver_thd, state_delaying_string); + THD_STAGE_INFO(sql_driver_thd, stage_sql_thd_waiting_until_delay); } int32 get_sql_delay() { return sql_delay; } diff --git a/sql/slave.cc b/sql/slave.cc index 5948d11825d..66b42cabcd4 100644 --- a/sql/slave.cc +++ b/sql/slave.cc @@ -3324,7 +3324,7 @@ static bool send_show_master_info_data(THD *thd, Master_info *mi, bool full, // to ensure that we use the same value throughout this function. const char *slave_sql_running_state= mi->rli.sql_driver_thd ? mi->rli.sql_driver_thd->proc_info : ""; - if (slave_sql_running_state == Relay_log_info::state_delaying_string) + if (slave_sql_running_state == stage_sql_thd_waiting_until_delay.m_name) { time_t t= my_time(0), sql_delay_end= mi->rli.get_sql_delay_end(); protocol->store((uint32)(t < sql_delay_end ? sql_delay_end - t : 0));