summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl/topology_coordinator.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/repl/topology_coordinator.h')
-rw-r--r--src/mongo/db/repl/topology_coordinator.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mongo/db/repl/topology_coordinator.h b/src/mongo/db/repl/topology_coordinator.h
index 361aa534ff2..184ba8ede52 100644
--- a/src/mongo/db/repl/topology_coordinator.h
+++ b/src/mongo/db/repl/topology_coordinator.h
@@ -691,6 +691,13 @@ public:
*/
boost::optional<OpTime> latestKnownOpTimeSinceHeartbeatRestart() const;
+ /**
+ * Similar to latestKnownOpTimeSinceHeartbeatRestart(), but returns the latest known optime for
+ * each member in the config. If the member is not up or hasn't responded to a heartbeat since
+ * we last restarted, then its value will be boost::none.
+ */
+ std::map<int, boost::optional<OpTime>> latestKnownOpTimeSinceHeartbeatRestartPerMember() const;
+
////////////////////////////////////////////////////////////
//
// Test support methods
@@ -845,6 +852,9 @@ private:
*/
bool _isElectableNodeInSingleNodeReplicaSet() const;
+ // Returns a string representation of the current replica set status for logging purposes.
+ std::string _getReplSetStatusString();
+
// This node's role in the replication protocol.
Role _role;