summaryrefslogtreecommitdiff
path: root/src/mongo/client/dbclient_base.h
diff options
context:
space:
mode:
authorBenety Goh <benety@mongodb.com>2020-02-19 10:17:21 -0500
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-02-19 15:49:41 +0000
commit21692cab486977a3c70f1a2a746ff12e5ffa3358 (patch)
treec57c1a81f4d8e7e39ad7c610c5c72a2de260d7b0 /src/mongo/client/dbclient_base.h
parentbc71c1dfefb4da9ba6592005ce35e21456ca7af3 (diff)
downloadmongo-21692cab486977a3c70f1a2a746ff12e5ffa3358.tar.gz
SERVER-39453 add DBClientBase::getReadyIndexSpecs()
Diffstat (limited to 'src/mongo/client/dbclient_base.h')
-rw-r--r--src/mongo/client/dbclient_base.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/mongo/client/dbclient_base.h b/src/mongo/client/dbclient_base.h
index ac4d302d172..5a3dfcfc766 100644
--- a/src/mongo/client/dbclient_base.h
+++ b/src/mongo/client/dbclient_base.h
@@ -510,9 +510,19 @@ public:
*/
virtual void createIndexes(StringData ns, const std::vector<BSONObj>& specs);
+ /**
+ * Lists indexes on the collection 'nsOrUuid'.
+ * Includes in-progress indexes.
+ */
virtual std::list<BSONObj> getIndexSpecs(const NamespaceStringOrUUID& nsOrUuid,
int options = 0);
+ /**
+ * Lists completed indexes on the collection 'nsOrUuid'.
+ */
+ virtual std::list<BSONObj> getReadyIndexSpecs(const NamespaceStringOrUUID& nsOrUuid,
+ int options = 0);
+
virtual void dropIndex(const std::string& ns, BSONObj keys);
virtual void dropIndex(const std::string& ns, const std::string& indexName);
@@ -730,6 +740,13 @@ protected:
std::vector<std::string> _saslMechsForAuth;
private:
+ /**
+ * Implementation for getIndexes() and getReadyIndexes().
+ */
+ std::list<BSONObj> _getIndexSpecs(const NamespaceStringOrUUID& nsOrUuid,
+ const BSONObj& cmd,
+ int options);
+
auth::RunCommandHook _makeAuthRunCommandHook();
/**