diff options
author | Eliot Horowitz <eliot@10gen.com> | 2013-10-30 09:53:25 -0400 |
---|---|---|
committer | Eliot Horowitz <eliot@10gen.com> | 2013-11-02 13:19:53 -0400 |
commit | 8bc2fd8c35414b99017068e68c505a2a1b14a2b2 (patch) | |
tree | e60cc2c832549b5f563ee552f07aa4b849923010 /src/mongo/db/index_legacy.cpp | |
parent | 8f73459ac4c750f9aaa957ec2c6e6569df43d8e4 (diff) | |
download | mongo-8bc2fd8c35414b99017068e68c505a2a1b14a2b2.tar.gz |
SERVER-11178: IndexLegacy partly to IndexCatalog
Diffstat (limited to 'src/mongo/db/index_legacy.cpp')
-rw-r--r-- | src/mongo/db/index_legacy.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/mongo/db/index_legacy.cpp b/src/mongo/db/index_legacy.cpp index 86e9cd88690..d76a0de8aa7 100644 --- a/src/mongo/db/index_legacy.cpp +++ b/src/mongo/db/index_legacy.cpp @@ -80,12 +80,13 @@ namespace mongo { } // static - void IndexLegacy::postBuildHook(NamespaceDetails* tableToIndex, const IndexDetails& idx) { + void IndexLegacy::postBuildHook(Collection* collection, IndexDescriptor* desc) { // If it's an FTS index, we want to set the power of 2 flag. - string pluginName = CatalogHack::getAccessMethodName(idx.keyPattern()); + string pluginName = collection->getIndexCatalog()->getAccessMethodName(desc->keyPattern()); if (IndexNames::TEXT == pluginName || IndexNames::TEXT_INTERNAL == pluginName) { - if (tableToIndex->setUserFlag(NamespaceDetails::Flag_UsePowerOf2Sizes)) { - tableToIndex->syncUserFlags(idx.parentNS()); + NamespaceDetails* nsd = collection->details(); + if (nsd->setUserFlag(NamespaceDetails::Flag_UsePowerOf2Sizes)) { + nsd->syncUserFlags(collection->ns().ns()); } } } |