diff options
Diffstat (limited to 'src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp')
-rw-r--r-- | src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp b/src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp index a4de16caf63..fa23b283c3a 100644 --- a/src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp +++ b/src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_init.cpp @@ -29,7 +29,6 @@ #include "mongo/platform/basic.h" -#include "mongo/base/init.h" #include "mongo/db/service_context.h" #include "mongo/db/storage/ephemeral_for_test/ephemeral_for_test_engine.h" #include "mongo/db/storage/kv/kv_storage_engine.h" @@ -69,12 +68,10 @@ public: } }; -} // namespace - -MONGO_INITIALIZER_WITH_PREREQUISITES(EphemeralForTestEngineInit, ("ServiceContext")) -(InitializerContext* context) { - registerStorageEngine(getGlobalServiceContext(), std::make_unique<EphemeralForTestFactory>()); - return Status::OK(); -} +ServiceContext::ConstructorActionRegisterer registerEphemeralForTest( + "RegisterEphemeralForTestEngine", [](ServiceContext* service) { + registerStorageEngine(service, std::make_unique<EphemeralForTestFactory>()); + }); +} // namespace } // namespace mongo |