summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mongo/db/repl/oplog.cpp2
-rw-r--r--src/mongo/db/storage/recovery_unit.h2
-rw-r--r--src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.cpp2
-rw-r--r--src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.h2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/db/repl/oplog.cpp b/src/mongo/db/repl/oplog.cpp
index d04c4823440..a098a5b7b38 100644
--- a/src/mongo/db/repl/oplog.cpp
+++ b/src/mongo/db/repl/oplog.cpp
@@ -155,7 +155,7 @@ void _getNextOpTimes(OperationContext* opCtx,
}
// Allow the storage engine to start the transaction outside the critical section.
- opCtx->recoveryUnit()->prepareSnapshot();
+ opCtx->recoveryUnit()->preallocateSnapshot();
stdx::lock_guard<stdx::mutex> lk(newOpMutex);
auto ts = LogicalClock::get(opCtx)->reserveTicks(count).asTimestamp();
diff --git a/src/mongo/db/storage/recovery_unit.h b/src/mongo/db/storage/recovery_unit.h
index 48d1e83ece4..bbc56dadb73 100644
--- a/src/mongo/db/storage/recovery_unit.h
+++ b/src/mongo/db/storage/recovery_unit.h
@@ -90,7 +90,7 @@ public:
* transaction resources while minimizing the critical section between generating a new
* timestamp and setting it using setTimestamp.
*/
- virtual void prepareSnapshot() {}
+ virtual void preallocateSnapshot() {}
/**
* Informs this RecoveryUnit that all future reads through it should be from a snapshot
diff --git a/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.cpp b/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.cpp
index cd520b9e5b6..2f37bad6783 100644
--- a/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.cpp
+++ b/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.cpp
@@ -179,7 +179,7 @@ void WiredTigerRecoveryUnit::abandonSnapshot() {
_areWriteUnitOfWorksBanned = false;
}
-void WiredTigerRecoveryUnit::prepareSnapshot() {
+void WiredTigerRecoveryUnit::preallocateSnapshot() {
// Begin a new transaction, if one is not already started.
getSession();
}
diff --git a/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.h b/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.h
index feccabf38e4..e41047967e8 100644
--- a/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.h
+++ b/src/mongo/db/storage/wiredtiger/wiredtiger_recovery_unit.h
@@ -70,7 +70,7 @@ public:
void registerChange(Change* change) override;
void abandonSnapshot() override;
- void prepareSnapshot() override;
+ void preallocateSnapshot() override;
Status setReadFromMajorityCommittedSnapshot() override;
bool isReadingFromMajorityCommittedSnapshot() const override {