diff options
author | Kyle Suarez <kyle.suarez@mongodb.com> | 2018-04-30 10:25:12 -0400 |
---|---|---|
committer | Kyle Suarez <kyle.suarez@mongodb.com> | 2018-04-30 11:14:59 -0400 |
commit | a9b53ada0db65e6ee341260c3256e960bac56a94 (patch) | |
tree | 17f359614f594c9427e982faa665578a05bd8728 /src/mongo/client | |
parent | 69b6d9846e3fae2fea9313757c7563b1061cf585 (diff) | |
download | mongo-a9b53ada0db65e6ee341260c3256e960bac56a94.tar.gz |
Revert "SERVER-32645 Create a shim helper framework."
This reverts commit 2227f272a7a0a3e43625cb2d4a2704e1ccb6f893.
Diffstat (limited to 'src/mongo/client')
-rw-r--r-- | src/mongo/client/embedded/embedded.cpp | 2 | ||||
-rw-r--r-- | src/mongo/client/embedded/index_create_impl_embedded.cpp | 12 |
2 files changed, 8 insertions, 6 deletions
diff --git a/src/mongo/client/embedded/embedded.cpp b/src/mongo/client/embedded/embedded.cpp index bc5b744d16c..6ad81043143 100644 --- a/src/mongo/client/embedded/embedded.cpp +++ b/src/mongo/client/embedded/embedded.cpp @@ -147,7 +147,7 @@ void shutdown(ServiceContext* srvContext) { { UninterruptibleLockGuard noInterrupt(shutdownOpCtx->lockState()); Lock::GlobalLock lk(shutdownOpCtx.get(), MODE_X, Date_t::max()); - DatabaseHolder::getDatabaseHolder().closeAll(shutdownOpCtx.get(), "shutdown"); + dbHolder().closeAll(shutdownOpCtx.get(), "shutdown"); // Shut down the background periodic task runner if (auto runner = serviceContext->getPeriodicRunner()) { diff --git a/src/mongo/client/embedded/index_create_impl_embedded.cpp b/src/mongo/client/embedded/index_create_impl_embedded.cpp index a58560f3945..de56784d039 100644 --- a/src/mongo/client/embedded/index_create_impl_embedded.cpp +++ b/src/mongo/client/embedded/index_create_impl_embedded.cpp @@ -44,12 +44,14 @@ class MultiIndexBlockImplEmbedded : public MultiIndexBlockImpl { return false; } }; -} // namespace -MONGO_REGISTER_SHIM(MultiIndexBlock::makeImpl) -(OperationContext* const opCtx, Collection* const collection, PrivateTo<MultiIndexBlock>) - ->std::unique_ptr<MultiIndexBlock::Impl> { - return std::make_unique<MultiIndexBlockImplEmbedded>(opCtx, collection); +MONGO_INITIALIZER(InitializeMultiIndexBlockFactory)(InitializerContext* const) { + MultiIndexBlock::registerFactory( + [](OperationContext* const opCtx, Collection* const collection) { + return stdx::make_unique<MultiIndexBlockImplEmbedded>(opCtx, collection); + }); + return Status::OK(); } +} // namespace } // namespace mongo |