-
Notifications
You must be signed in to change notification settings - Fork 53
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: prevent hanging by call backgroundResources.close() on stub.close() [ggj] #804
Merged
Merged
Changes from 10 commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
9ea4717
feat(ast): Add support for throwable causes
miraleung 4ac2d79
fix: call backgroundResources.close() on stub.close()
miraleung 01c0f1a
Merge branch 'master' of github.com:googleapis/gapic-generator-java i…
miraleung f15ec26
Merge branch 'dev/throw-cause' of github.com:googleapis/gapic-generat…
miraleung 70b657b
Merge branch 'master' into dev/throw-cause
miraleung e72e2e9
Merge branch 'master' into dev/throw-cause
miraleung 5ea11bf
fix: make Throwable a static final in TypeNode
miraleung 897c881
Merge branch 'dev/throw-cause' of github.com:googleapis/gapic-generat…
miraleung 3c85b99
Merge branch 'dev/throw-cause' of github.com:googleapis/gapic-generat…
miraleung fdd1f44
Merge branch 'dev/throw-cause' of github.com:googleapis/gapic-generat…
miraleung 17a1440
Merge branch 'master' of github.com:googleapis/gapic-generator-java i…
miraleung bf55a60
Merge branch 'master' into dev/stub-close
miraleung 7ea5032
fix: update goldens
miraleung f986360
Merge branch 'dev/stub-close' of github.com:googleapis/gapic-generato…
miraleung d5fc5cf
feat(ast): support throwing all kinds of expressions
miraleung 68fb465
fix: call backgroundResources.close() on stub.close()
miraleung 6de4e5e
fix: update goldens
miraleung 1c57844
feat(ast): Add support for multi-catch blocks
miraleung 12c8836
fix: add extra catch block
miraleung d683370
Merge branch 'dev/stub-close' of github.com:googleapis/gapic-generato…
miraleung 552af72
fix: isolate stub.close change to another PR
miraleung 741d685
Merge branch 'dev/try-catch-list' of github.com:googleapis/gapic-gene…
miraleung e959ac1
fix: merge branches
miraleung File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Looks like this (exception wrapping) exists solely because
backgroundResources.close()
is checked (throws Exception
), but theEchoStub.close()
is declared as non-checked, so we need do something like that for things to compile. Either way it will be a breaking behavioral change. To mitigate it, I think we can wrap only what we must (checked exceptions), but throw as is all the unchecked exceptions, so please consider generating somethign like this instead:This will let us to avoid unnecessary exception wrapping, making this change differ less from the previous behavior.
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.
Done.