diff options
author | Tess Avitabile <tess.avitabile@mongodb.com> | 2018-02-14 13:33:44 -0500 |
---|---|---|
committer | Tess Avitabile <tess.avitabile@mongodb.com> | 2018-02-14 17:35:25 -0500 |
commit | c927a61213f5e1e80d7535b6cb1a16f23a6d0b98 (patch) | |
tree | 7c72e5cd3fe8f4f9f36d1fa1c5fc3d2f20ed866a /src/mongo/db/concurrency/locker.h | |
parent | e5e8dde676b585f5620608e95e93b9da295890c5 (diff) | |
download | mongo-c927a61213f5e1e80d7535b6cb1a16f23a6d0b98.tar.gz |
SERVER-33004 Add two-phase locking for shared locks for snapshot reads
Diffstat (limited to 'src/mongo/db/concurrency/locker.h')
-rw-r--r-- | src/mongo/db/concurrency/locker.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/db/concurrency/locker.h b/src/mongo/db/concurrency/locker.h index a8690ce2d37..3e70d000fe8 100644 --- a/src/mongo/db/concurrency/locker.h +++ b/src/mongo/db/concurrency/locker.h @@ -90,6 +90,11 @@ public: virtual stdx::thread::id getThreadId() const = 0; /** + * Indicate that shared locks should participate in two-phase locking for this Locker instance. + */ + virtual void setSharedLocksShouldTwoPhaseLock(bool sharedLocksShouldTwoPhaseLock) = 0; + + /** * This should be the first method invoked for a particular Locker object. It acquires the * Global lock in the specified mode and effectively indicates the mode of the operation. * This is what the lock modes on the global lock mean: |