-
Notifications
You must be signed in to change notification settings - Fork 81
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
fix: More robust STREAM_RST logic #1102
Conversation
return status.getCode() == Status.Code.INTERNAL | ||
&& status.getDescription() != null | ||
&& (status.getDescription().contains("Received unexpected EOS on DATA frame from server") | ||
|| status.getDescription().contains("Received Rst ") |
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.
Nit: is there a reason to drop " Stream" here?
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.
Yes, from PR description:
The capitalization of "Rst Stream" isn't clear, other repose have it lower cased: (e.g. https://github.com/googleapis/java-bigtable-hbase/pull/3000/files)
Please update initial commit and subject line of this PR to abide by conventional commit rules. |
google-cloud-bigquerystorage/src/main/java/com/google/cloud/bigquery/storage/util/Errors.java
Outdated
Show resolved
Hide resolved
|| status.getDescription().contains("Received Rst ") | ||
|| status.getDescription().contains("RST_STREAM")); |
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.
Can we just check for status.getDescription.toLowercase().contains("rst")
?
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 don't think so. "rst" can occur naturally in other settings. I shortened the top one to just be " Rst ". I also added some other messages from spark-bigquery-connector.
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.
okay lgtm thank you!
...e-cloud-bigquerystorage/src/test/java/com/google/cloud/bigquery/storage/util/ErrorsTest.java
Outdated
Show resolved
Hide resolved
…gquery/storage/util/Errors.java Co-authored-by: Stephanie Wang <stephaniewang526@users.noreply.github.com>
…gquery/storage/util/ErrorsTest.java Co-authored-by: Stephanie Wang <stephaniewang526@users.noreply.github.com>
🤖 I have created a release \*beep\* \*boop\* --- ## [1.22.0](https://www.github.com/googleapis/java-bigquerystorage/compare/v1.21.1...v2.0.0) (2021-05-31) ### ⚠ BREAKING CHANGES * remove default deadline for AppendRows API (#1101) ### Features * add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#1092](https://www.github.com/googleapis/java-bigquerystorage/issues/1092)) ([9fe34d1](https://www.github.com/googleapis/java-bigquerystorage/commit/9fe34d1a7ea2b4c1f750fd8805251811a4b0111d)) ### Bug Fixes * More robust STREAM_RST logic ([#1102](https://www.github.com/googleapis/java-bigquerystorage/issues/1102)) ([dd67534](https://www.github.com/googleapis/java-bigquerystorage/commit/dd675343b20d614eaf715306f1151532a3a2c33f)) * remove default deadline for AppendRows API ([#1101](https://www.github.com/googleapis/java-bigquerystorage/issues/1101)) ([87cadf0](https://www.github.com/googleapis/java-bigquerystorage/commit/87cadf01edbdaf876699e98f027835d6594f8072)) ### Dependencies * update arrow.version to v4.0.1 ([#1103](https://www.github.com/googleapis/java-bigquerystorage/issues/1103)) ([b2e3489](https://www.github.com/googleapis/java-bigquerystorage/commit/b2e34894f443075ce375b822babcfc329b34c76c)) * update dependency com.google.truth:truth to v1.1.3 ([#1100](https://www.github.com/googleapis/java-bigquerystorage/issues/1100)) ([12c401f](https://www.github.com/googleapis/java-bigquerystorage/commit/12c401feec1fb7fbaf39ea7ccffee4a02faffeb3)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
This change makes error matching against stream rst more robust. Customers have started to see other variants with RST stream. The capitalization of "Rst Stream" isn't clear, other repose have it lower cased: (e.g. https://github.com/googleapis/java-bigtable-hbase/pull/3000/files)