aboutsummaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcore/proton/server/fast_access_document_retriever.h
blob: 524a68589012a85751283622bc219c59b38b99fa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once

#include "documentretriever.h"
#include "fast_access_feed_view.h"
#include <vespa/searchcore/proton/attribute/i_attribute_manager.h>

namespace proton {

/**
 * The document retriever used by the fast-access sub database.
 *
 * Handles retrieving of documents by combining from the underlying attribute manager
 * and document store.
 */
class FastAccessDocumentRetriever : public DocumentRetriever
{
private:
    FastAccessFeedView::SP   _feedView;
    IAttributeManager::SP    _attrMgr;

public:
    FastAccessDocumentRetriever(FastAccessFeedView::SP feedView, IAttributeManager::SP attrMgr);
    ~FastAccessDocumentRetriever() override;
    uint32_t getDocIdLimit() const override { return _feedView->getDocIdLimit().get(); }
};

} // namespace proton