diff options
author | Scott Hernandez <scotthernandez@gmail.com> | 2015-10-02 06:55:07 -0400 |
---|---|---|
committer | Scott Hernandez <scotthernandez@gmail.com> | 2015-10-02 06:55:07 -0400 |
commit | f25e8acf1a160bbfa39035888bb026049b10ae22 (patch) | |
tree | 85737402daf2439fa60ae1e02a74316fc6aac3f3 /src/mongo/db/repl/sync_tail.cpp | |
parent | 4372e7b826bbaff94d995c0a37d9a8bf29378e48 (diff) | |
download | mongo-f25e8acf1a160bbfa39035888bb026049b10ae22.tar.gz |
Revert "SERVER-18983: Apply oplog and record in oplog concurrently"
This reverts commit 3937e8a5a855aebc4c8e16206fd69c863f567e15.
Diffstat (limited to 'src/mongo/db/repl/sync_tail.cpp')
-rw-r--r-- | src/mongo/db/repl/sync_tail.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/db/repl/sync_tail.cpp b/src/mongo/db/repl/sync_tail.cpp index 182c9a47994..5ceb240989d 100644 --- a/src/mongo/db/repl/sync_tail.cpp +++ b/src/mongo/db/repl/sync_tail.cpp @@ -333,6 +333,7 @@ void applyOps(const std::vector<std::vector<BSONObj>>& writerVectors, writerPool->schedule(func, stdx::cref(*it), sync); } } + writerPool->join(); } void fillWriterVectors(const std::deque<BSONObj>& ops, @@ -400,12 +401,11 @@ OpTime SyncTail::multiApply(OperationContext* txn, const OpQueue& ops) { applyOps(writerVectors, &_writerPool, _applyFunc, this); - OpTime lastOpTime = writeOpsToOplog(txn, ops.getDeque()); if (inShutdown()) { return OpTime(); } - _writerPool.join(); - // We have now written all database writes and updated the oplog to match. + + OpTime lastOpTime = writeOpsToOplog(txn, ops.getDeque()); ReplClientInfo::forClient(txn->getClient()).setLastOp(lastOpTime); replCoord->setMyLastOptime(lastOpTime); |