diff options
author | Vesselina Ratcheva <vesselina.ratcheva@10gen.com> | 2019-03-05 13:50:45 -0500 |
---|---|---|
committer | Vesselina Ratcheva <vesselina.ratcheva@10gen.com> | 2019-03-06 12:16:11 -0500 |
commit | 1fe923eec6c301f554ec5a5cfb9a40ebf4318e13 (patch) | |
tree | efd6b29a00d32358c3f295a57c79def4d70747ac /src/mongo/db/concurrency/locker.h | |
parent | a6a424f3961bec9e2311fa78a10e563d98ed2e88 (diff) | |
download | mongo-1fe923eec6c301f554ec5a5cfb9a40ebf4318e13.tar.gz |
SERVER-39139 Make lock mode for ReplicationStateTransitionLockGuard configurable
Diffstat (limited to 'src/mongo/db/concurrency/locker.h')
-rw-r--r-- | src/mongo/db/concurrency/locker.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mongo/db/concurrency/locker.h b/src/mongo/db/concurrency/locker.h index 3c5653f39bc..ae951b4715b 100644 --- a/src/mongo/db/concurrency/locker.h +++ b/src/mongo/db/concurrency/locker.h @@ -196,20 +196,20 @@ public: virtual bool unlockGlobal() = 0; /** - * Requests the RSTL to be acquired in mode X. This should only be called inside - * ReplicationStateTransitionLockGuard. + * Requests the RSTL to be acquired in the requested mode (typically mode X) . This should only + * be called inside ReplicationStateTransitionLockGuard. * * See the comments for lockBegin/Complete for more information on the semantics. */ - virtual LockResult lockRSTLBegin(OperationContext* opCtx) = 0; + virtual LockResult lockRSTLBegin(OperationContext* opCtx, LockMode mode) = 0; /** - * Waits for the completion of acquiring the RSTL in mode X. This should only be called inside + * Waits for the completion of acquiring the RSTL. This should only be called inside * ReplicationStateTransitionLockGuard. * * It may throw an exception if it is interrupted. */ - virtual void lockRSTLComplete(OperationContext* opCtx, Date_t deadline) = 0; + virtual void lockRSTLComplete(OperationContext* opCtx, LockMode mode, Date_t deadline) = 0; /** * Unlocks the RSTL when the transaction becomes prepared. This is used to bypass two-phase |