summaryrefslogtreecommitdiffstats
path: root/searchcore/src/apps/tests/persistenceconformance_test.cpp
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2021-04-13 07:47:33 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2021-04-13 07:47:33 +0000
commit045babd97ccd8ba1bf44c14d0bce326c1f1a57be (patch)
tree625e9ed63e07c80f4895bd2608821507a4b1b121 /searchcore/src/apps/tests/persistenceconformance_test.cpp
parentf9cc338cc28a79045da882db7ddcc8e02cb301df (diff)
Force having documentdb as shared_ptr.
Diffstat (limited to 'searchcore/src/apps/tests/persistenceconformance_test.cpp')
-rw-r--r--searchcore/src/apps/tests/persistenceconformance_test.cpp30
1 files changed, 7 insertions, 23 deletions
diff --git a/searchcore/src/apps/tests/persistenceconformance_test.cpp b/searchcore/src/apps/tests/persistenceconformance_test.cpp
index d28e7a1f8d3..69d509c25fd 100644
--- a/searchcore/src/apps/tests/persistenceconformance_test.cpp
+++ b/searchcore/src/apps/tests/persistenceconformance_test.cpp
@@ -192,34 +192,18 @@ public:
config::DirSpec spec(inputCfg + "/config-1");
TuneFileDocumentDB::SP tuneFileDocDB(new TuneFileDocumentDB());
DocumentDBConfigHelper mgr(spec, docType.getName());
- BootstrapConfig::SP b(new BootstrapConfig(1,
- factory.getTypeCfg(),
- factory.getTypeRepo(),
+ auto b = std::make_shared<BootstrapConfig>(1, factory.getTypeCfg(), factory.getTypeRepo(),
std::make_shared<ProtonConfig>(),
std::make_shared<FiledistributorrpcConfig>(),
std::make_shared<BucketspacesConfig>(),
- tuneFileDocDB, HwInfo()));
+ tuneFileDocDB, HwInfo());
mgr.forwardConfig(b);
mgr.nextGeneration(0ms);
- return std::make_shared<DocumentDB>(_baseDir,
- mgr.getConfig(),
- _tlsSpec,
- _queryLimiter,
- _clock,
- docType,
- bucketSpace,
- *b->getProtonConfigSP(),
- const_cast<DocumentDBFactory &>(*this),
- _summaryExecutor,
- _summaryExecutor,
- _bucketExecutor,
- _tls,
- _metricsWireService,
- _fileHeaderContext,
- _config_stores.getConfigStore(docType.toString()),
- std::make_shared<vespalib::ThreadStackExecutor>
- (16, 128_Ki),
- HwInfo());
+ return DocumentDB::create(_baseDir, mgr.getConfig(), _tlsSpec, _queryLimiter, _clock, docType, bucketSpace,
+ *b->getProtonConfigSP(), const_cast<DocumentDBFactory &>(*this),
+ _summaryExecutor, _summaryExecutor, _bucketExecutor, _tls, _metricsWireService,
+ _fileHeaderContext, _config_stores.getConfigStore(docType.toString()),
+ std::make_shared<vespalib::ThreadStackExecutor>(16, 128_Ki), HwInfo());
}
};