summaryrefslogtreecommitdiff
path: root/src/mongo/s/mongos_topology_coordinator.h
diff options
context:
space:
mode:
authorPavi Vetriselvan <pvselvan@umich.edu>2020-04-30 10:51:05 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-05-13 16:23:43 +0000
commit3b4e9894e2971c2b42b83c336a48068810c91a9c (patch)
tree48f4042773c607a11cd94291a7027caa442bbe81 /src/mongo/s/mongos_topology_coordinator.h
parentb2384a85f62431d88ac01067ae4d1d3dbb4fede5 (diff)
downloadmongo-3b4e9894e2971c2b42b83c336a48068810c91a9c.tar.gz
SERVER-46957 Implement Quiesce Mode for mongos
Diffstat (limited to 'src/mongo/s/mongos_topology_coordinator.h')
-rw-r--r--src/mongo/s/mongos_topology_coordinator.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/mongo/s/mongos_topology_coordinator.h b/src/mongo/s/mongos_topology_coordinator.h
index 903a17aa2ca..708de6a1241 100644
--- a/src/mongo/s/mongos_topology_coordinator.h
+++ b/src/mongo/s/mongos_topology_coordinator.h
@@ -64,13 +64,19 @@ public:
/**
* We only enter quiesce mode during the shutdown process, which means the
- * MongosTopologyCoordinator will never need to exit quiesce mode. While in quiesce mode, we
- * allow operations to continue and accept new operations, but we fail isMaster requests with
- * ShutdownInProgress. This function causes us to increment the topologyVersion and start
- * failing isMaster requests with ShutdownInProgress.
+ * MongosTopologyCoordinator will never need to exit quiesce mode. This function causes us to
+ * increment the topologyVersion and start failing isMaster requests with ShutdownInProgress.
*/
void enterQuiesceMode();
+ /**
+ * While in quiesce mode, we will sleep for 100ms. This allows short running operations to
+ * continue. We will also accept new operations, but we fail isMaster requests with
+ * ShutdownInProgress.
+ * TODO SERVER-46958: Modify comment with correct timeout value.
+ */
+ void enterQuiesceModeAndWait(OperationContext* opCtx);
+
TopologyVersion getTopologyVersion() const {
stdx::lock_guard lk(_mutex);
return _topologyVersion;