Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
luwei16 committed Aug 29, 2024
1 parent 230426f commit 498cd2a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
3 changes: 2 additions & 1 deletion be/src/olap/tablet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1017,7 +1017,8 @@ uint32_t Tablet::calc_compaction_score(
// Need meta lock, because it will iterator "all_rs_metas" of tablet meta.
std::shared_lock rdlock(_meta_lock);
if (compaction_type == CompactionType::CUMULATIVE_COMPACTION) {
_cumu_compaction_score = _calc_cumulative_compaction_score(cumulative_compaction_policy);
_cumu_compaction_score =
_calc_cumulative_compaction_score(cumulative_compaction_policy);
_cumu_score_obsolete = false;
return _cumu_compaction_score;
} else {
Expand Down
16 changes: 4 additions & 12 deletions be/src/olap/tablet.h
Original file line number Diff line number Diff line change
Expand Up @@ -481,13 +481,9 @@ class Tablet final : public BaseTablet {
inline bool is_full_compaction_running() const { return _is_full_compaction_running; }
void clear_cache() override;

bool is_cumu_compaction_score_obsolete() const {
return _cumu_score_obsolete;
}
bool is_cumu_compaction_score_obsolete() const { return _cumu_score_obsolete; }

bool is_base_compaction_score_obsolete() const {
return _base_score_obsolete;
}
bool is_base_compaction_score_obsolete() const { return _base_score_obsolete; }

void set_cumu_compaction_score_obsolete(int32_t compaction_score) {
_cumu_score_obsolete = compaction_score;
Expand All @@ -497,17 +493,13 @@ class Tablet final : public BaseTablet {
_base_score_obsolete = compaction_score;
}

int32_t get_cumu_compaction_score() const {
return _cumu_compaction_score;
}
int32_t get_cumu_compaction_score() const { return _cumu_compaction_score; }

void set_cumu_compaction_score(int32_t compaction_score) {
_cumu_compaction_score = compaction_score;
}

int32_t get_base_compaction_score() const {
return _base_compaction_score;
}
int32_t get_base_compaction_score() const { return _base_compaction_score; }

void set_base_compaction_score(int32_t compaction_score) {
_base_compaction_score = compaction_score;
Expand Down

0 comments on commit 498cd2a

Please sign in to comment.