Skip to content

Commit b7c46d4

Browse files
authored
feat(storage): limit hummock write based on LSM tree stats (risingwavelabs#8383)
1 parent 4b49428 commit b7c46d4

File tree

21 files changed

+665
-50
lines changed

21 files changed

+665
-50
lines changed

dashboard/proto/gen/hummock.ts

Lines changed: 148 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dashboard/proto/gen/meta.ts

Lines changed: 38 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

proto/hummock.proto

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -519,6 +519,7 @@ message RiseCtlUpdateCompactionConfigRequest {
519519
uint64 target_file_size_base = 7;
520520
uint32 compaction_filter_mask = 8;
521521
uint32 max_sub_compaction = 9;
522+
uint64 level0_stop_write_threshold_sub_level_number = 10;
522523
}
523524
}
524525
repeated uint64 compaction_group_ids = 1;
@@ -602,6 +603,8 @@ message CompactionConfig {
602603
uint32 max_sub_compaction = 12;
603604
uint64 max_space_reclaim_bytes = 13;
604605
bool split_by_state_table = 14;
606+
// soft limit for max number of sub level number
607+
uint64 level0_stop_write_threshold_sub_level_number = 15;
605608
}
606609

607610
message TableStats {
@@ -614,3 +617,12 @@ message HummockVersionStats {
614617
uint64 hummock_version_id = 1;
615618
map<uint32, TableStats> table_stats = 2;
616619
}
620+
621+
message WriteLimits {
622+
message WriteLimit {
623+
repeated uint32 table_ids = 1;
624+
string reason = 2;
625+
}
626+
// < compaction group id, write limit info >
627+
map<uint64, WriteLimit> write_limits = 1;
628+
}

0 commit comments

Comments
 (0)