diff options
author | Benety Goh <benety@mongodb.com> | 2016-09-19 15:05:41 -0400 |
---|---|---|
committer | Benety Goh <benety@mongodb.com> | 2016-09-20 14:49:58 -0400 |
commit | 963d2a0d952a65e84157aa52bc4d71a40fcb9707 (patch) | |
tree | 9a93b9052989129411fb744812f6869c161a3c82 /src/mongo/db/repl/oplog_buffer_collection.cpp | |
parent | ad9f3df970b0b7d2465268e1d34d5198d7296298 (diff) | |
download | mongo-963d2a0d952a65e84157aa52bc4d71a40fcb9707.tar.gz |
SERVER-25268 added StorageInterfaceImpl::findOne and deleteOne support for startKey and boundInclusion
Diffstat (limited to 'src/mongo/db/repl/oplog_buffer_collection.cpp')
-rw-r--r-- | src/mongo/db/repl/oplog_buffer_collection.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mongo/db/repl/oplog_buffer_collection.cpp b/src/mongo/db/repl/oplog_buffer_collection.cpp index 65082937bc8..e77431a54cd 100644 --- a/src/mongo/db/repl/oplog_buffer_collection.cpp +++ b/src/mongo/db/repl/oplog_buffer_collection.cpp @@ -217,7 +217,8 @@ bool OplogBufferCollection::_pop_inlock(OperationContext* txn, Value* value) { return true; } auto scanDirection = StorageInterface::ScanDirection::kForward; - auto result = _storageInterface->deleteOne(txn, _nss, kIdIdxName, scanDirection); + auto result = _storageInterface->deleteOne( + txn, _nss, kIdIdxName, scanDirection, {}, BoundInclusion::kIncludeStartKeyOnly); if (!result.isOK()) { if (result != ErrorCodes::CollectionIsEmpty) { fassert(40162, result.getStatus()); @@ -244,7 +245,8 @@ bool OplogBufferCollection::_peekOneSide_inlock(OperationContext* txn, } auto scanDirection = front ? StorageInterface::ScanDirection::kForward : StorageInterface::ScanDirection::kBackward; - auto result = _storageInterface->findOne(txn, _nss, kIdIdxName, scanDirection); + auto result = _storageInterface->findOne( + txn, _nss, kIdIdxName, scanDirection, {}, BoundInclusion::kIncludeStartKeyOnly); if (!result.isOK()) { if (result != ErrorCodes::CollectionIsEmpty) { fassert(40163, result.getStatus()); |