summaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h
diff options
context:
space:
mode:
Diffstat (limited to 'searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h')
-rw-r--r--searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h b/searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h
index 4b7058fdb83..39fde4f5fb7 100644
--- a/searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h
+++ b/searchcore/src/vespa/searchcore/proton/attribute/imported_attributes_context.h
@@ -2,6 +2,7 @@
#pragma once
#include <vespa/searchcommon/attribute/iattributecontext.h>
+#include <vespa/searchlib/common/i_document_meta_store_context.h>
#include <vespa/vespalib/stllike/hash_fun.h>
#include <vespa/vespalib/stllike/hash_map.h>
#include <mutex>
@@ -30,13 +31,16 @@ private:
using IAttributeVector = search::attribute::IAttributeVector;
using ImportedAttributeVector = search::attribute::ImportedAttributeVector;
using IAttributeFunctor = search::attribute::IAttributeFunctor;
+ using MetaStoreReadGuard = search::IDocumentMetaStoreContext::IReadGuard;
using AttributeCache = std::unordered_map<vespalib::string, std::unique_ptr<AttributeReadGuard>, vespalib::hash<vespalib::string>>;
+ using MetaStoreCache = std::unordered_map<const void *, std::shared_ptr<MetaStoreReadGuard>>;
using LockGuard = std::lock_guard<std::mutex>;
const ImportedAttributesRepo &_repo;
mutable AttributeCache _guardedAttributes;
mutable AttributeCache _enumGuardedAttributes;
+ mutable MetaStoreCache _metaStores;
mutable std::mutex _cacheMutex;
const IAttributeVector *getOrCacheAttribute(const vespalib::string &name, AttributeCache &attributes,