Hello Alexey Serbin, Zoltan Martonka, Kudu Jenkins, Abhishek Chennaka,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/24694
to look at the new patch set (#2).
Change subject: KUDU-3791 add metrics for auto-leader-rebalancer
......................................................................
KUDU-3791 add metrics for auto-leader-rebalancer
Before this change, log grepping was the only way to see what the
auto-leader-rebalancer was doing. Adds six counters on the master:
- auto_leader_rebalancer_moves_scheduled
- auto_leader_rebalancer_moves_completed
- auto_leader_rebalancer_moves_failed
- auto_leader_rebalancer_rounds_completed
- auto_leader_rebalancer_global_pass_skipped
- auto_leader_rebalancer_task_errors (MetricLevel::kWarn)
Naming and units mirror the counters AutoRebalancerTask already
exposes, so the two tasks read as a matched pair on /metrics.
The three move counters keep the invariant
moves_scheduled = moves_completed + moves_failed
over transfers we actually tried, i.e. once we've committed to
sending the LeaderStepDown RPC. Planned moves that turn out to be
stale by the time we get to executing (source tserver deregistered,
destination now in maintenance mode) are skipped without touching
any of the three.
task_errors is warn-severity and meant as the main alerting signal.
It's bumped in RunLoop() when RunLeaderRebalancer() returns an
unexpected error. Losing catalog-manager leadership mid-round is
now swallowed like the first ScopedLeaderSharedLock check already
does, so a leader flap on its own doesn't bump the counter.
Adds a LeaderRebalancerTest.RebalancerMetrics test that exercises
all six counters and asserts the invariant.
Change-Id: I49b86e59043a7f652d4f556b94582bb74c5698ad
---
M src/kudu/master/auto_leader_rebalancer-test.cc
M src/kudu/master/auto_leader_rebalancer.cc
M src/kudu/master/auto_leader_rebalancer.h
M src/kudu/master/catalog_manager.cc
4 files changed, 248 insertions(+), 18 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/94/24694/2
--
To view, visit http://gerrit.cloudera.org:8080/24694
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I49b86e59043a7f652d4f556b94582bb74c5698ad
Gerrit-Change-Number: 24694
Gerrit-PatchSet: 2
Gerrit-Owner: Gabriella Lotz <[email protected]>
Gerrit-Reviewer: Abhishek Chennaka <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Gabriella Lotz <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Zoltan Martonka <[email protected]>