summaryrefslogtreecommitdiff
path: root/src/mongo/db/catalog/drop_collection.h
diff options
context:
space:
mode:
authorPierlauro Sciarelli <pierlauro.sciarelli@mongodb.com>2021-09-21 19:07:29 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-09-21 19:33:14 +0000
commit7ed02f5c9b4f295b661903a27b872536927f76e9 (patch)
treee39b11ccb88638980b9388b7573260edbdefbb06 /src/mongo/db/catalog/drop_collection.h
parent2598db31541746d191e29f9f7236cb8d9a825774 (diff)
downloadmongo-7ed02f5c9b4f295b661903a27b872536927f76e9.tar.gz
SERVER-60007 Implement command to drop collection if its UUID differs from the expected
Diffstat (limited to 'src/mongo/db/catalog/drop_collection.h')
-rw-r--r--src/mongo/db/catalog/drop_collection.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mongo/db/catalog/drop_collection.h b/src/mongo/db/catalog/drop_collection.h
index 43362d3cb11..e6cd613f260 100644
--- a/src/mongo/db/catalog/drop_collection.h
+++ b/src/mongo/db/catalog/drop_collection.h
@@ -57,6 +57,13 @@ Status dropCollection(OperationContext* opCtx,
DropCollectionSystemCollectionMode systemCollectionMode);
/**
+ * Drops the collection "collectionName" only if its uuid is not matching "expectedUUID".
+ */
+Status dropCollectionIfUUIDNotMatching(OperationContext* opCtx,
+ const NamespaceString& ns,
+ const UUID& expectedUUID);
+
+/**
* Drops the collection "collectionName". When applying a 'drop' oplog entry on a secondary, the
* 'dropOpTime' will contain the optime of the oplog entry.
*/