mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-23 16:22:15 +00:00
stcs: inline function definition so as not to break one definition rule
goal is to allow multiple definitions of header Signed-off-by: Raphael S. Carvalho <raphaelsc@scylladb.com>
This commit is contained in:
@@ -156,7 +156,7 @@ public:
|
||||
friend std::vector<sstables::shared_sstable> size_tiered_most_interesting_bucket(const std::vector<sstables::shared_sstable>&);
|
||||
};
|
||||
|
||||
std::vector<std::pair<sstables::shared_sstable, uint64_t>>
|
||||
inline std::vector<std::pair<sstables::shared_sstable, uint64_t>>
|
||||
size_tiered_compaction_strategy::create_sstable_and_length_pairs(const std::vector<sstables::shared_sstable>& sstables) const {
|
||||
|
||||
std::vector<std::pair<sstables::shared_sstable, uint64_t>> sstable_length_pairs;
|
||||
@@ -172,7 +172,7 @@ size_tiered_compaction_strategy::create_sstable_and_length_pairs(const std::vect
|
||||
return sstable_length_pairs;
|
||||
}
|
||||
|
||||
std::vector<std::vector<sstables::shared_sstable>>
|
||||
inline std::vector<std::vector<sstables::shared_sstable>>
|
||||
size_tiered_compaction_strategy::get_buckets(const std::vector<sstables::shared_sstable>& sstables) const {
|
||||
// sstables sorted by size of its data file.
|
||||
auto sorted_sstables = create_sstable_and_length_pairs(sstables);
|
||||
@@ -227,7 +227,7 @@ size_tiered_compaction_strategy::get_buckets(const std::vector<sstables::shared_
|
||||
return bucket_list;
|
||||
}
|
||||
|
||||
std::vector<sstables::shared_sstable>
|
||||
inline std::vector<sstables::shared_sstable>
|
||||
size_tiered_compaction_strategy::most_interesting_bucket(std::vector<std::vector<sstables::shared_sstable>> buckets,
|
||||
unsigned min_threshold, unsigned max_threshold)
|
||||
{
|
||||
@@ -262,7 +262,8 @@ size_tiered_compaction_strategy::most_interesting_bucket(std::vector<std::vector
|
||||
return hottest;
|
||||
}
|
||||
|
||||
compaction_descriptor size_tiered_compaction_strategy::get_sstables_for_compaction(column_family& cfs, std::vector<sstables::shared_sstable> candidates) {
|
||||
inline compaction_descriptor
|
||||
size_tiered_compaction_strategy::get_sstables_for_compaction(column_family& cfs, std::vector<sstables::shared_sstable> candidates) {
|
||||
// make local copies so they can't be changed out from under us mid-method
|
||||
int min_threshold = cfs.schema()->min_compaction_threshold();
|
||||
int max_threshold = cfs.schema()->max_compaction_threshold();
|
||||
@@ -299,7 +300,7 @@ compaction_descriptor size_tiered_compaction_strategy::get_sstables_for_compacti
|
||||
return sstables::compaction_descriptor();
|
||||
}
|
||||
|
||||
int64_t size_tiered_compaction_strategy::estimated_pending_compactions(column_family& cf) const {
|
||||
inline int64_t size_tiered_compaction_strategy::estimated_pending_compactions(column_family& cf) const {
|
||||
int min_threshold = cf.schema()->min_compaction_threshold();
|
||||
int max_threshold = cf.schema()->max_compaction_threshold();
|
||||
std::vector<sstables::shared_sstable> sstables;
|
||||
|
||||
Reference in New Issue
Block a user