reset lock_wait_mgr's node's need_wait_ when doing local_retry
This commit is contained in:
parent
7c53d6573e
commit
e17bb817f5
1
deps/oblib/src/rpc/ob_lock_wait_node.cpp
vendored
1
deps/oblib/src/rpc/ob_lock_wait_node.cpp
vendored
@ -45,6 +45,7 @@ void ObLockWaitNode::set(void* addr,
|
||||
total_update_cnt_ = total_trans_node_cnt;
|
||||
run_ts_ = 0;
|
||||
snprintf(key_, sizeof(key_), "%s", key);
|
||||
reset_need_wait();
|
||||
}
|
||||
|
||||
void ObLockWaitNode::change_hash(const int64_t hash, const int64_t lock_seq)
|
||||
|
@ -17,6 +17,7 @@
|
||||
#include "sql/resolver/ob_stmt.h"
|
||||
#include "pl/ob_pl.h"
|
||||
#include "storage/tx/ob_trans_define.h"
|
||||
#include "storage/memtable/ob_lock_wait_mgr.h"
|
||||
#include "observer/mysql/ob_mysql_result_set.h"
|
||||
#include "observer/ob_server_struct.h"
|
||||
#include "observer/mysql/obmp_query.h"
|
||||
@ -988,6 +989,13 @@ void ObQueryRetryCtrl::after_func(ObRetryParam &v)
|
||||
if (OB_UNLIKELY(OB_SUCCESS == v.client_ret_)) {
|
||||
LOG_ERROR_RET(OB_ERR_UNEXPECTED, "no matter need retry or not, v.client_ret_ should not be OB_SUCCESS", K(v));
|
||||
}
|
||||
// bug fix:
|
||||
if (RETRY_TYPE_LOCAL == v.retry_type_) {
|
||||
rpc::ObLockWaitNode* node = MTL(memtable::ObLockWaitMgr*)->get_thread_node();
|
||||
if (NULL != node) {
|
||||
node->reset_need_wait();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int ObQueryRetryCtrl::init()
|
||||
|
Loading…
x
Reference in New Issue
Block a user