diff options
Diffstat (limited to 'src/mongo/db/catalog/rename_collection.cpp')
-rw-r--r-- | src/mongo/db/catalog/rename_collection.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mongo/db/catalog/rename_collection.cpp b/src/mongo/db/catalog/rename_collection.cpp index 69ceb35a556..f1f259f1410 100644 --- a/src/mongo/db/catalog/rename_collection.cpp +++ b/src/mongo/db/catalog/rename_collection.cpp @@ -545,6 +545,9 @@ Status renameBetweenDBs(OperationContext* opCtx, // The generated unique collection name is only guaranteed to exist if the database is // exclusively locked. invariant(opCtx->lockState()->isDbLockedForMode(targetDB->name(), LockMode::MODE_X)); + + // Note that this temporary collection name is used by MongoMirror and thus must not be changed + // without consultation. auto tmpNameResult = targetDB->makeUniqueCollectionNamespace(opCtx, "tmp%%%%%.renameCollection"); if (!tmpNameResult.isOK()) { |