diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-03-01 13:21:39 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-03-01 13:21:39 +0200 |
commit | 0b6f193194fc2a8e981264ad03336ba94972d46a (patch) | |
tree | e1d5925300d9becd1f0770b5ecf0c8c9d53f5801 | |
parent | 1c21a9d27ab568486d55e0b49a78e12c04178e6f (diff) | |
download | mariadb-git-0b6f193194fc2a8e981264ad03336ba94972d46a.tar.gz |
WIP: Work around parallel replication hangs
This is not a real fix! It reduces the probability of hangs in
the following tests to practically non-existent:
rpl.rpl_parallel_optimistic
rpl.rpl_parallel_optimistic_xa_lsu_off
rpl.rpl_parallel_optimistic_nobinlog
-rw-r--r-- | storage/innobase/lock/lock0lock.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/storage/innobase/lock/lock0lock.cc b/storage/innobase/lock/lock0lock.cc index cf86de51fcd..660a8421187 100644 --- a/storage/innobase/lock/lock0lock.cc +++ b/storage/innobase/lock/lock0lock.cc @@ -5469,14 +5469,14 @@ void lock_sys_t::cancel(trx_t *trx, lock_t *lock) /** Cancel a waiting lock request (if any) when killing a transaction */ void lock_sys_t::cancel(trx_t *trx) { - lock_sys.rd_lock(SRW_LOCK_CALL); + lock_sys.wr_lock(SRW_LOCK_CALL); mysql_mutex_lock(&lock_sys.wait_mutex); if (lock_t *lock= trx->lock.wait_lock) { trx->error_state= DB_INTERRUPTED; cancel(trx, lock); } - lock_sys.rd_unlock(); + lock_sys.wr_unlock(); lock_sys.deadlock_check(); mysql_mutex_unlock(&lock_sys.wait_mutex); } |