aboutsummaryrefslogtreecommitdiffstats
path: root/searchcore/src/vespa/searchcore/bmcluster/bm_storage_chain_builder.h
blob: 053c0d3e42124cccad2701bf92d431c81f2202d4 (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
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

#include <vespa/storage/common/storage_chain_builder.h>

namespace search::bmcluster {

struct BmStorageLinkContext;

/*
 * Storage chain builder that inserts a BmStorageLink right below the
 * communication manager. This allows sending benchmark feed to chain.
 */
class BmStorageChainBuilder : public storage::StorageChainBuilder
{
    std::shared_ptr<BmStorageLinkContext> _context;
public:
    BmStorageChainBuilder();
    ~BmStorageChainBuilder() override;
    const std::shared_ptr<BmStorageLinkContext>& get_context() { return _context; }
    void add(std::unique_ptr<storage::StorageLink> link) override;
};

}