diff options
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index b39be36a9dd..9608c07b45a 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -4826,12 +4826,31 @@ public: LOG_INFO *current_linfo; Slave_info *slave_info; + /* + Indicates if this thread is suspended due to awaiting an ACK from a + replica. True if suspended, false otherwise. + */ + bool awaiting_semisync_ack; + void set_current_linfo(LOG_INFO *linfo); void reset_current_linfo() { set_current_linfo(0); } + void set_awaiting_semisync_ack(bool status) + { + mysql_mutex_assert_owner(&LOCK_thd_data); + awaiting_semisync_ack= status; + } + int register_slave(uchar *packet, size_t packet_length); void unregister_slave(); bool is_binlog_dump_thread(); + bool is_awaiting_semisync_ack() + { + mysql_mutex_lock(&LOCK_thd_data); + bool res= awaiting_semisync_ack; + mysql_mutex_unlock(&LOCK_thd_data); + return res; + } #endif inline ulong wsrep_binlog_format() const |