summaryrefslogtreecommitdiff
path: root/src/mongo/dbtests
diff options
context:
space:
mode:
authorVesselina Ratcheva <vesselina.ratcheva@10gen.com>2019-03-12 18:18:13 -0400
committerVesselina Ratcheva <vesselina.ratcheva@10gen.com>2019-03-19 13:41:23 -0400
commitab74d3a236d05f6cab9bfbc39594ba9527920e03 (patch)
tree8093848a7639b4c07ed03d1c6c83da62ec80aae7 /src/mongo/dbtests
parentdef336dd7510b42c7fbdea22030d0ef5c39bd541 (diff)
downloadmongo-ab74d3a236d05f6cab9bfbc39594ba9527920e03.tar.gz
SERVER-39989 Store start timestamp as optime in config.transactions
Diffstat (limited to 'src/mongo/dbtests')
-rw-r--r--src/mongo/dbtests/storage_timestamp_tests.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mongo/dbtests/storage_timestamp_tests.cpp b/src/mongo/dbtests/storage_timestamp_tests.cpp
index c2800a6a882..54a823d9b79 100644
--- a/src/mongo/dbtests/storage_timestamp_tests.cpp
+++ b/src/mongo/dbtests/storage_timestamp_tests.cpp
@@ -420,14 +420,14 @@ public:
ASSERT_EQ(TransactionParticipant::getOldestActiveTimestamp(_opCtx), ts);
}
- void assertHasStartTimestamp() {
+ void assertHasStartOpTime() {
auto txnDoc = _getTxnDoc();
- ASSERT_TRUE(txnDoc.hasField(SessionTxnRecord::kStartTimestampFieldName));
+ ASSERT_TRUE(txnDoc.hasField(SessionTxnRecord::kStartOpTimeFieldName));
}
- void assertNoStartTimestamp() {
+ void assertNoStartOpTime() {
auto txnDoc = _getTxnDoc();
- ASSERT_FALSE(txnDoc.hasField(SessionTxnRecord::kStartTimestampFieldName));
+ ASSERT_FALSE(txnDoc.hasField(SessionTxnRecord::kStartOpTimeFieldName));
}
void setReplCoordAppliedOpTime(const repl::OpTime& opTime) {
@@ -2790,7 +2790,7 @@ public:
txnParticipant.commitUnpreparedTransaction(_opCtx);
txnParticipant.stashTransactionResources(_opCtx);
- assertNoStartTimestamp();
+ assertNoStartOpTime();
{
AutoGetCollection autoColl(_opCtx, nss, LockMode::MODE_X, LockMode::MODE_IX);
auto coll = autoColl.getCollection();
@@ -3215,7 +3215,7 @@ public:
txnParticipant.prepareTransaction(_opCtx, {});
txnParticipant.stashTransactionResources(_opCtx);
- assertHasStartTimestamp();
+ assertHasStartOpTime();
{
const auto prepareFilter = BSON("ts" << prepareTs);
assertOplogDocumentExistsAtTimestamp(prepareFilter, presentTs, false);
@@ -3240,7 +3240,7 @@ public:
txnParticipant.unstashTransactionResources(_opCtx, "commitTransaction");
txnParticipant.commitPreparedTransaction(_opCtx, commitEntryTs, {});
- assertNoStartTimestamp();
+ assertNoStartOpTime();
txnParticipant.stashTransactionResources(_opCtx);
{
@@ -3312,7 +3312,7 @@ public:
txnParticipant.prepareTransaction(_opCtx, {});
txnParticipant.stashTransactionResources(_opCtx);
- assertHasStartTimestamp();
+ assertHasStartOpTime();
{
const auto prepareFilter = BSON("ts" << prepareTs);
assertOplogDocumentExistsAtTimestamp(prepareFilter, presentTs, false);
@@ -3337,7 +3337,7 @@ public:
txnParticipant.unstashTransactionResources(_opCtx, "abortTransaction");
txnParticipant.abortActiveTransaction(_opCtx);
- assertNoStartTimestamp();
+ assertNoStartOpTime();
txnParticipant.stashTransactionResources(_opCtx);
{