-
Notifications
You must be signed in to change notification settings - Fork 735
hot_region: check leader during handle expired item #9372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: okJiang <[email protected]>
Skipping CI for Draft Pull Request. |
/retest |
/cc @lhy1024 |
/retest |
Signed-off-by: okJiang <[email protected]>
c.GetHotStat().CheckWriteAsync(checkExpiredTask) | ||
c.GetHotStat().CheckReadAsync(checkExpiredTask) | ||
c.GetHotStat().CheckReadAsync(checkLeaderChangeTask) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we check it for Write?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to reuse checkWritePeerTask?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if need to do this check with write
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think justTransferLeader
handles the leader change case in CheckPeerFlow
, so it shouldn't run checkLeaderChangeTask
on Write anymore.
Maybe we should strip out the relevant logic from CheckPeerFlow
. But the code(CheckPeerFlow
) is kind of crappy right now, and I don't really think of a better way to abstract it away.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It may need to be checked with write.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lhy1024 Did you see this reply? #9372 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right. We only need to solve hot read change by store heartbeat.
Signed-off-by: okJiang <[email protected]>
c.GetHotStat().CheckWriteAsync(checkExpiredTask) | ||
c.GetHotStat().CheckReadAsync(checkExpiredTask) | ||
c.GetHotStat().CheckReadAsync(checkLeaderChangeTask) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It may need to be checked with write.
[LGTM Timeline notifier]Timeline:
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: lhy1024 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
What problem does this PR solve?
Issue Number: Close #9366
What is changed and how does it work?
Check List
Tests
Release note