Skip to content
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

Finer is_retry_request settings #763

Merged
merged 3 commits into from
Apr 10, 2023
Merged

Conversation

ekexium
Copy link
Contributor

@ekexium ekexium commented Apr 4, 2023

Close #762
Set is_retry_request only for requests that is possible to have undermined errors.
For example, prewrite requests that have only met RegionError errors will not set this flag.

For reviewers: the format tool adjusts some unrelated code snippets. Please just ignore them.

@ekexium ekexium force-pushed the finer-retry-flag branch from ebc8ed0 to f885bf9 Compare April 4, 2023 05:09
…ermined errors

Signed-off-by: ekexium <eke@fastmail.com>
@ekexium ekexium force-pushed the finer-retry-flag branch from f885bf9 to 9c1bb5d Compare April 4, 2023 05:13
@ekexium
Copy link
Contributor Author

ekexium commented Apr 4, 2023

@cfzjywxk @MyonKeminta PTAL

Copy link
Contributor

@MyonKeminta MyonKeminta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rest LGTM

return resp, err
func (s *RegionRequestSender) SendReq(
bo *retry.Backoffer, req *tikvrpc.Request, regionID RegionVerID, timeout time.Duration,
) (*tikvrpc.Response, int, error) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new return value tryTimes will be zero when it succeeds without retrying, right? I think it sounds more like retryTimes 😕 Can you add to the comment above about what's the new return value's exact meaning?

Signed-off-by: ekexium <eke@fastmail.com>
@cfzjywxk cfzjywxk merged commit f3e8703 into tikv:master Apr 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Finer setting of is_retry_request
3 participants