From a9c27ee3ca2373ba17b12db6321c3e45e293fdaf Mon Sep 17 00:00:00 2001 From: chinaxing Date: Fri, 24 Feb 2023 15:41:32 +0000 Subject: [PATCH] [master][xa][tx-route] fix xa trans state sync sanity check --- src/storage/tx/ob_tx_free_route.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/storage/tx/ob_tx_free_route.cpp b/src/storage/tx/ob_tx_free_route.cpp index 07f5e9a971..34684a9965 100644 --- a/src/storage/tx/ob_tx_free_route.cpp +++ b/src/storage/tx/ob_tx_free_route.cpp @@ -271,7 +271,8 @@ int ObTransService::txn_free_route__update_static_state(const uint32_t session_i need_add_tx = true; } else { // update - if (tx->state_ != ObTxDesc::State::IDLE) { + // NOTE: for XA join/resume will cause `static state` re-synced + if (tx->state_ != ObTxDesc::State::IDLE && !tx->is_xa_trans()) { ret = OB_ERR_UNEXPECTED; ObSpinLockGuard guard(tx->lock_); TRANS_LOG(ERROR, "txn static update must with IDLE state", K(ret), K(session_id), KPC(tx));