summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl/replication_coordinator_impl.h
diff options
context:
space:
mode:
authorMisha Tyulenev <misha@mongodb.com>2017-06-21 22:18:58 -0400
committerMisha Tyulenev <misha@mongodb.com>2017-06-21 22:20:08 -0400
commit48dc747414e18d8caa56f0fba23c80871f67c31a (patch)
treedffe91c2fc1c792ce45b199a3deab9dedc702c07 /src/mongo/db/repl/replication_coordinator_impl.h
parent358cf1d12d8c3787fe14fe4458a242186d12b3c0 (diff)
downloadmongo-48dc747414e18d8caa56f0fba23c80871f67c31a.tar.gz
SERVER-28150 Add support for readConcern::afterClusterTime for level == local
Diffstat (limited to 'src/mongo/db/repl/replication_coordinator_impl.h')
-rw-r--r--src/mongo/db/repl/replication_coordinator_impl.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/mongo/db/repl/replication_coordinator_impl.h b/src/mongo/db/repl/replication_coordinator_impl.h
index 4bdb1cd4daf..e0ed3a93ff3 100644
--- a/src/mongo/db/repl/replication_coordinator_impl.h
+++ b/src/mongo/db/repl/replication_coordinator_impl.h
@@ -1094,18 +1094,24 @@ private:
executor::TaskExecutor::EventHandle _cancelElectionIfNeeded_inlock();
/**
+ * Waits until the optime of the current node is at least the 'opTime'.
+ */
+ Status _waitUntilOpTime(OperationContext* opCtx, bool isMajorityReadConcern, OpTime opTime);
+
+ /**
* Waits until the optime of the current node is at least the opTime specified in 'readConcern'.
- * It supports local readConcern, which _waitUntilClusterTimeForRead does not.
- * TODO: remove when SERVER-28150 is done.
+ * Supports local and majority readConcern.
*/
+ // TODO: remove when SERVER-29729 is done
Status _waitUntilOpTimeForReadDeprecated(OperationContext* opCtx,
const ReadConcernArgs& readConcern);
/**
- * Waits until the logicalTime of the current node is at least the 'clusterTime'.
- * TODO: Merge with waitUntilOpTimeForRead() when SERVER-28150 is done.
+ * Waits until the optime of the current node is at least the clusterTime specified in
+ * 'readConcern'. Supports local and majority readConcern.
*/
- Status _waitUntilClusterTimeForRead(OperationContext* opCtx, LogicalTime clusterTime);
+ Status _waitUntilClusterTimeForRead(OperationContext* opCtx,
+ const ReadConcernArgs& readConcern);
/**
* Returns a pseudorandom number no less than 0 and less than limit (which must be positive).