blob: 88eac32fc7608158ef0127c5745ad12a5c022bad (
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
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include "posting_store_memory_usage.h"
#include <vespa/searchcommon/attribute/iattributevector.h>
namespace vespalib::datastore { class CompactionStrategy; }
namespace vespalib { class MemoryUsage; }
namespace search::attribute {
class IPostingListAttributeBase
{
public:
using CompactionStrategy = vespalib::datastore::CompactionStrategy;
virtual ~IPostingListAttributeBase() = default;
virtual void clearPostings(IAttributeVector::EnumHandle eidx, uint32_t fromLid, uint32_t toLid) = 0;
virtual void forwardedShrinkLidSpace(uint32_t newSize) = 0;
virtual PostingStoreMemoryUsage getMemoryUsage() const = 0;
virtual bool consider_compact_worst_btree_nodes(const CompactionStrategy& compaction_strategy) = 0;
virtual bool consider_compact_worst_buffers(const CompactionStrategy& compaction_strategy) = 0;
};
}
|