Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/24618 )
Change subject: [compaction] budget refinements and observability ...................................................................... Patch Set 2: (7 comments) http://gerrit.cloudera.org:8080/#/c/24618/2//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/24618/2//COMMIT_MSG@7 PS2, Line 7: [compaction] budget refinements and observability nit: does this come under some umbrella JIRA ticket? If yes, maybe mention this in the summary line for easier tracking/backporting. http://gerrit.cloudera.org:8080/#/c/24618/2//COMMIT_MSG@27 PS2, Line 27: Metrics to detect slow scans caused by budget-induced compaction lag Are these per-tablet or total for a tablet server? Would be nice to clarify in the description. http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/diskrowset.cc File src/kudu/tablet/diskrowset.cc: http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/diskrowset.cc@838 PS2, Line 838: // Clamp the weight to [0.0, 1.0] to guard against misconfiguration. : const double undo_weight = : std::max(0.0, std::min(1.0, FLAGS_rowset_undo_deltas_budget_weight)); Maybe, add a flag validator for rowset_undo_deltas_budget_weight to be more explicit about misconfiguration? http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet.cc File src/kudu/tablet/tablet.cc: http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet.cc@2570 PS2, Line 2570: ret.size() - 1 - components_->txn_memrowsets.size(); nit: add a DCHECK() to make sure there isn't an underflow of unsigned integer? http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet.cc@2589 PS2, Line 2589: const size_t num_rs_iters = : ret.size() - 1 - components_->txn_memrowsets.size(); ditto http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet_metrics.cc File src/kudu/tablet/tablet_metrics.cc: http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet_metrics.cc@447 PS2, Line 447: or because they fell outside the winning " : "key range chosen by the compaction policy Isn't it quite common to have a situation where there many other rowsets with higher scores because of current key range/width distribution, but the algorithm eventually picks up the rowset after merging other rowsets? I guess this part might be a noise that we wouldn't actually like to see, no? http://gerrit.cloudera.org:8080/#/c/24618/2/src/kudu/tablet/tablet_metrics.cc@462 PS2, Line 462: METRIC_DEFINE_gauge_uint32(tablet, compaction_budget_skip_health, : "Compaction Budget Health", : kudu::MetricUnit::kUnits, : "Health indicator for compaction budget adequacy. Set to 1 (degraded) " : "when one or more DiskRowSets are individually larger than " : "--tablet_compaction_budget_mb and can therefore never be selected for " : "merge compaction under the current settings. A degraded state means " : "affected rowsets will accumulate indefinitely, which may cause slow scans. " : "Set to 0 (healthy) when all candidate rowsets fit within the budget. " : "To resolve a degraded state, increase --tablet_compaction_budget_mb or, " : "if --rowset_deltas_size_include_undo is enabled, lower " : "--rowset_undo_deltas_budget_weight.", : kudu::MetricLevel::kWarn); >From the monitoring perspective, it might be quite cumbersome to watch for >this metric across thousands of tablets. Consider adding an accumulative >server-wide kWarn gauge that would report on the number of tablets in >not-so-good health in this sense, and switch this one into kInfo category. -- To view, visit http://gerrit.cloudera.org:8080/24618 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Id63db0006c77ad1d55eb2119d99ee64499435819 Gerrit-Change-Number: 24618 Gerrit-PatchSet: 2 Gerrit-Owner: Ashwani Raina <[email protected]> Gerrit-Reviewer: Alexey Serbin <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Wed, 29 Jul 2026 16:18:07 +0000 Gerrit-HasComments: Yes
