diff options
author | Geir Storli <geirst@yahooinc.com> | 2022-03-17 14:14:58 +0000 |
---|---|---|
committer | Geir Storli <geirst@yahooinc.com> | 2022-03-17 14:14:58 +0000 |
commit | defcc21484db806f8ccf47a6864006fc54cfe193 (patch) | |
tree | 6a2d07e2b5669b722a25bf677c21c47685f28b3a /searchcore/src/tests/proton/documentdb/documentdb_test.cpp | |
parent | 791812f39d990fb75c11cccb72334b21bf220630 (diff) |
Make the attribute enum change interlock shared between all document dbs.
This is to avoid a potential deadlock when using imported attributes in parent/child.
Diffstat (limited to 'searchcore/src/tests/proton/documentdb/documentdb_test.cpp')
-rw-r--r-- | searchcore/src/tests/proton/documentdb/documentdb_test.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/searchcore/src/tests/proton/documentdb/documentdb_test.cpp b/searchcore/src/tests/proton/documentdb/documentdb_test.cpp index 0edea2c0c5c..a9f923833e5 100644 --- a/searchcore/src/tests/proton/documentdb/documentdb_test.cpp +++ b/searchcore/src/tests/proton/documentdb/documentdb_test.cpp @@ -2,10 +2,12 @@ #include <tests/proton/common/dummydbowner.h> #include <vespa/config-bucketspaces.h> +#include <vespa/config/subscription/sourcespec.h> #include <vespa/document/config/documenttypes_config_fwd.h> #include <vespa/document/datatype/documenttype.h> #include <vespa/document/repo/documenttyperepo.h> #include <vespa/document/test/make_bucket_space.h> +#include <vespa/fnet/transport.h> #include <vespa/searchcore/proton/attribute/flushableattribute.h> #include <vespa/searchcore/proton/common/statusreport.h> #include <vespa/searchcore/proton/docsummary/summaryflushtarget.h> @@ -26,6 +28,7 @@ #include <vespa/searchcore/proton/test/mock_shared_threading_service.h> #include <vespa/searchcorespi/index/indexflushtarget.h> #include <vespa/searchlib/attribute/attribute_read_guard.h> +#include <vespa/searchlib/attribute/interlock.h> #include <vespa/searchlib/index/dummyfileheadercontext.h> #include <vespa/searchlib/transactionlog/translogserver.h> #include <vespa/vespalib/data/slime/slime.h> @@ -33,8 +36,6 @@ #include <vespa/vespalib/stllike/asciistream.h> #include <vespa/vespalib/testkit/test_kit.h> #include <vespa/vespalib/util/size_literals.h> -#include <vespa/config/subscription/sourcespec.h> -#include <vespa/fnet/transport.h> #include <iostream> using namespace cloud::config::filedistribution; @@ -165,7 +166,9 @@ Fixture::Fixture(bool file_config) _db = DocumentDB::create(".", mgr.getConfig(), "tcp/localhost:9014", _queryLimiter, DocTypeName("typea"), makeBucketSpace(), *b->getProtonConfigSP(), _myDBOwner, _shared_service, _tls, _dummy, - _fileHeaderContext, make_config_store(), + _fileHeaderContext, + std::make_shared<search::attribute::Interlock>(), + make_config_store(), std::make_shared<vespalib::ThreadStackExecutor>(16, 128_Ki), _hwInfo); _db->start(); _db->waitForOnlineState(); |