arshilkxwork commented on PR #3356:
URL: https://github.com/apache/hugegraph/pull/3356#issuecomment-6237398994
Thanks. Addressed in 67b2dc2da, without changing the algorithm.
- The 1000-entry check is now described as an estimated, best-effort gap: in
the comments on `BALANCE_LEADER_MAX_INDEX_GAP` and `canTakeLeader`, in the skip
log line ("at an estimated N"), in `configuration.md` and in the PR
description. Each says a late burst can keep a caught-up Store waiting and an
early burst can let a Store that fell behind through, with JRaft's transfer
timeout bounding the second case.
- New tests, using your numbers:
- `testAutoBalancePartitionLeaderWithLateBurst`: 7000 to 10000 over 300 s,
store 3 caught up at 7000 and reporting 15 s earlier. The estimate puts the
leader at 9850, so store 3 waits and store 2 takes both transfers.
- `testAutoBalancePartitionLeaderWithEarlyBurst`: 7000 to 10000 over 30 s,
store 3 at 8500 and reporting 15 s earlier. It passes and takes two leaders;
the test comment notes it could have been 1500 behind.
- `testAutoBalancePartitionLeaderWithNewerFollowerReport`: store 3 reports
15 s after the leader. At 11400 it takes two leaders, at 10000 (1500 behind the
estimated 11500) it waits, and with no earlier run the same reports compare as
equal.
- History wording: the field comment now says the entry is used only while
the same Store leads the group, is cleared by a run that finds this PD is not
the leader, and is not tied to a leadership term. A PD that loses and regains
leadership, or a leader that moves away and back, between two runs keeps the
entry, and the rate is averaged over that time. The docs say "no usable earlier
sample from the same leader Store" where they said "first run".
PD core suite: 165 tests, 0 failures, 2 skipped.
The `pd_store / hstore` failure on 57bd3d19b is in CI setup: the start
script appends `usePD=true` on every start, so `init-store.sh` reads `[true,
true]` and exits before any API test runs. Other PRs failed the same way today,
and #3371 fixes the script.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]