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

tikv: fix infinite panic when GRPC transportReader is broken (#18437) #18562

Merged
merged 3 commits into from
Jul 15, 2020

Conversation

ti-srebot
Copy link
Contributor

cherry-pick #18437 to release-4.0


What problem does this PR solve?

Issue Number: refer #18339

Problem Summary:

when panic like #18339 happened, batchClient will recovery from panic without reCreate stream and meet panic again and again...

What is changed and how it works?

What's Changed, How it Works:

although we didn't know how to broke transportReader, we can break infinite panic by covert panic to an error in recv method, then the error will trigger reCreate stream

image

make it recovery from broken transportReader

Related changes

  • Need to cherry-pick to the release branch 4.0

Check List

Tests

  • Manual test (add detailed scripts or steps below)

Side effects

  • n/a

Release note

  • Fix infinite panic when GRPC transportReader is broken

This change is Reviewable

Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Contributor Author

/run-all-tests

@lysu
Copy link
Contributor

lysu commented Jul 15, 2020

/run-integration-copr-test

@coocood
Copy link
Member

coocood commented Jul 15, 2020

LGTM

@ti-srebot ti-srebot added the status/LGT1 Indicates that a PR has LGTM 1. label Jul 15, 2020
@cfzjywxk
Copy link
Contributor

LGTM

@ti-srebot ti-srebot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Jul 15, 2020
@coocood
Copy link
Member

coocood commented Jul 15, 2020

/merge

@ti-srebot ti-srebot added the status/can-merge Indicates a PR has been approved by a committer. label Jul 15, 2020
@lysu
Copy link
Contributor

lysu commented Jul 15, 2020

/merge

@ti-srebot
Copy link
Contributor Author

Sorry @lysu, you don't have permission to trigger auto merge event on this branch.

@ti-srebot
Copy link
Contributor Author

/run-all-tests

@ti-srebot
Copy link
Contributor Author

/run-all-tests

@ti-srebot
Copy link
Contributor Author

@ti-srebot merge failed.

@winoros
Copy link
Member

winoros commented Jul 15, 2020

/run-sqllogic-test-1

@winoros
Copy link
Member

winoros commented Jul 15, 2020

/run-unit-test

@coocood coocood merged commit 17711d8 into pingcap:release-4.0 Jul 15, 2020
@coocood coocood deleted the release-4.0-ca41972fbac0 branch July 15, 2020 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/tikv priority/release-blocker This issue blocks a release. Please solve it ASAP. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. type/bugfix This PR fixes a bug. type/4.0-cherry-pick
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants