RATIS-2382. Support skip leadership check during ReadIndex#1334
RATIS-2382. Support skip leadership check during ReadIndex#1334ivandika3 wants to merge 1 commit intoapache:masterfrom
Conversation
| | **Default** | false | | ||
|
|
||
|
|
||
| | **Property** | `raft.server.read.read-index.heartbeat.skip.enabled` | |
There was a problem hiding this comment.
LGTM for the idea and code.
Just want to discuss whether heartbeat.skip.enabled is a good name, I think maybe raft.server.read.read-index.leadership-check.skip.enabled
There was a problem hiding this comment.
@OneSizeFitsQuorum Thanks for the review. I was also grappling with whether "leadership check" is a better name. However, my reasoning of choosing "heartbeat" is because we already have a LeaderStateImpl#checkLeadership to decide whether to leader need to step down due to lost majority heartbeats. LeaderStateImpl#checkLeadership does not send heartbeat, it simply checks the last RPC response time of the majority. Therefore, I picked "heartbeat" to explicitly mention the RPC that is going to be skipped.
That said, I'm ok if the community decide "leadership-check" is a more fitting name.
What changes were proposed in this pull request?
Please refer to https://issues.apache.org/jira/browse/RATIS-2382
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/RATIS-2382
How was this patch tested?
CI (https://github.com/ivandika3/ratis/actions/runs/20984539273)