summaryrefslogtreecommitdiff
path: root/src/mongo/db/transaction/transaction_participant.cpp
diff options
context:
space:
mode:
authorseanzimm <sean.zimmerman@mongodb.com>2023-02-09 22:30:31 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2023-02-10 01:41:43 +0000
commitc835341f9706373fb46ba7a6fc37d9892c42a967 (patch)
treed1fd0ec93b46894bf6db78e496d8fe1e49f6dcf7 /src/mongo/db/transaction/transaction_participant.cpp
parent66d62e802b3e952b73daf61545fd31158f198189 (diff)
downloadmongo-c835341f9706373fb46ba7a6fc37d9892c42a967.tar.gz
SERVER-70642: Add ticket acquisition skip for node step up
Diffstat (limited to 'src/mongo/db/transaction/transaction_participant.cpp')
-rw-r--r--src/mongo/db/transaction/transaction_participant.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/mongo/db/transaction/transaction_participant.cpp b/src/mongo/db/transaction/transaction_participant.cpp
index ca711476df9..72df0adddd4 100644
--- a/src/mongo/db/transaction/transaction_participant.cpp
+++ b/src/mongo/db/transaction/transaction_participant.cpp
@@ -1598,9 +1598,7 @@ void TransactionParticipant::Participant::refreshLocksForPreparedTransaction(
invariant(o().txnResourceStash);
invariant(o().txnState.isPrepared());
- // Lock and Ticket reacquisition of a prepared transaction should not fail for
- // state transitions (step up/step down).
- _releaseTransactionResourcesToOpCtx(opCtx, MaxLockTimeout::kNotAllowed, AcquireTicket::kNoSkip);
+ _releaseTransactionResourcesToOpCtx(opCtx, MaxLockTimeout::kNotAllowed, AcquireTicket::kSkip);
// Snapshot transactions don't conflict with PBWM lock on both primary and secondary.
invariant(!opCtx->lockState()->shouldConflictWithSecondaryBatchApplication());