summaryrefslogtreecommitdiff
path: root/src/mongo/db/repair_database.cpp
diff options
context:
space:
mode:
authorGeert Bosch <geert@mongodb.com>2017-05-04 18:36:07 -0400
committerGeert Bosch <geert@mongodb.com>2017-05-08 13:51:34 -0400
commit71c05d54c1e0f05e4e99ceda9ee7deb3c6a6b247 (patch)
tree0d12cd7318f03cdf9afe89509b56a55f403c82dd /src/mongo/db/repair_database.cpp
parentbd678a44e7b087753024b27b2a75a465e00c7b89 (diff)
downloadmongo-71c05d54c1e0f05e4e99ceda9ee7deb3c6a6b247.tar.gz
SERVER-29088 Cache uuid in Collection class to fix perf regression
Diffstat (limited to 'src/mongo/db/repair_database.cpp')
-rw-r--r--src/mongo/db/repair_database.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/db/repair_database.cpp b/src/mongo/db/repair_database.cpp
index 615604ba8dc..70405da7928 100644
--- a/src/mongo/db/repair_database.cpp
+++ b/src/mongo/db/repair_database.cpp
@@ -143,7 +143,8 @@ Status rebuildIndexesOnCollection(OperationContext* opCtx,
// open a bad index and fail.
// TODO see if MultiIndexBlock can be made to work without a Collection.
const StringData ns = cce->ns().ns();
- collection.reset(new Collection(opCtx, ns, cce, dbce->getRecordStore(ns), dbce));
+ const auto uuid = cce->getCollectionOptions(opCtx).uuid;
+ collection.reset(new Collection(opCtx, ns, uuid, cce, dbce->getRecordStore(ns), dbce));
indexer.reset(new MultiIndexBlock(opCtx, collection.get()));
Status status = indexer->init(indexSpecs).getStatus();