summaryrefslogtreecommitdiff
path: root/src/mongo/db/keys_collection_manager.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/keys_collection_manager.h')
-rw-r--r--src/mongo/db/keys_collection_manager.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/mongo/db/keys_collection_manager.h b/src/mongo/db/keys_collection_manager.h
index bfe4a27a408..9333ba284d9 100644
--- a/src/mongo/db/keys_collection_manager.h
+++ b/src/mongo/db/keys_collection_manager.h
@@ -98,6 +98,11 @@ public:
*/
void enableKeyGenerator(OperationContext* opCtx, bool doEnable);
+ /**
+ * Returns true if the refresher has ever successfully returned keys from the config server.
+ */
+ bool hasSeenKeys();
+
private:
/**
* This is responsible for periodically performing refresh in the background.
@@ -143,6 +148,11 @@ private:
*/
void stop();
+ /**
+ * Returns true if keys have ever successfully been returned from the config server.
+ */
+ bool hasSeenKeys();
+
private:
void _doPeriodicRefresh(ServiceContext* service,
std::string threadName,
@@ -155,6 +165,7 @@ private:
stdx::thread _backgroundThread;
std::shared_ptr<RefreshFunc> _doRefresh;
+ bool _hasSeenKeys = false;
bool _inShutdown = false;
};