diff options
author | mkaruza <mario.karuza@galeracluster.com> | 2021-04-26 11:17:30 +0200 |
---|---|---|
committer | Jan Lindström <jan.lindstrom@mariadb.com> | 2021-04-28 11:11:01 +0300 |
commit | 206d630ea0c1f89f6c3bd2b8d3d62eafa37a2bc2 (patch) | |
tree | 5eb74e8c5f41abcc449d15944ddf17f5d18c9e7d /sql/wsrep_mysqld.cc | |
parent | 4cd92143eae9b397589e5b449d1a85c43b3e4f6b (diff) | |
download | mariadb-git-206d630ea0c1f89f6c3bd2b8d3d62eafa37a2bc2.tar.gz |
MDEV-22227 Assertion `state_ == s_exec' failed in wsrep::client_state::start_transactionbb-10.4-MDEV-22227
Removed redundant code for BF abort transaction in `thr_lock.cc`.
TOI operations will ignore provided lock_wait_timeout and use `LONG_TIMEOUT`
until operation is finished.
Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
Diffstat (limited to 'sql/wsrep_mysqld.cc')
-rw-r--r-- | sql/wsrep_mysqld.cc | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/sql/wsrep_mysqld.cc b/sql/wsrep_mysqld.cc index 0f0ef95492b..195b882a3fb 100644 --- a/sql/wsrep_mysqld.cc +++ b/sql/wsrep_mysqld.cc @@ -872,9 +872,6 @@ void wsrep_init_startup (bool sst_first) { if (wsrep_init()) unireg_abort(1); - wsrep_thr_lock_init(wsrep_thd_is_BF, wsrep_thd_bf_abort, - wsrep_debug, wsrep_convert_LOCK_to_trx, wsrep_on); - /* Pre-initialize global_system_variables.table_plugin with a dummy engine (placeholder) required during the initialization of wsrep threads (THDs). @@ -2194,6 +2191,13 @@ int wsrep_to_isolation_begin(THD *thd, const char *db_, const char *table_, thd->variables.auto_increment_increment= 1; } + /* + TOI operations will ignore provided lock_wait_timeout and restore it + after operation is done. + */ + thd->variables.saved_lock_wait_timeout= thd->variables.lock_wait_timeout; + thd->variables.lock_wait_timeout= LONG_TIMEOUT; + if (thd->variables.wsrep_on && wsrep_thd_is_local(thd)) { switch (thd->variables.wsrep_OSU_method) { @@ -2228,6 +2232,9 @@ void wsrep_to_isolation_end(THD *thd) { DBUG_ASSERT(wsrep_thd_is_local_toi(thd) || wsrep_thd_is_in_rsu(thd)); + + thd->variables.lock_wait_timeout= thd->variables.saved_lock_wait_timeout; + if (wsrep_thd_is_local_toi(thd)) { DBUG_ASSERT(thd->variables.wsrep_OSU_method == WSREP_OSU_TOI); |