Make sure that background resources are closed when the PubSub subscriber fails - #6238
Merged
Merged
Conversation
hannahrogers-google
suggested changes
Sep 18, 2019
hannahrogers-google
left a comment
Contributor
There was a problem hiding this comment.
@mdirkse, thanks for your PR! Looks good - just a small change requested for the unit test
Contributor
|
@mdirkse, did you want to take a look at the requested changes so that we can merge this PR? |
Author
|
Yes! Sorry, will do so today. |
mdirkse
force-pushed
the
master
branch
2 times, most recently
from
October 17, 2019 19:45
4f40b49 to
70a0bc6
Compare
hannahrogers-google
approved these changes
Oct 21, 2019
hannahrogers-google
left a comment
Contributor
There was a problem hiding this comment.
Thanks @mdirkse!
Codecov Report
@@ Coverage Diff @@
## master #6238 +/- ##
============================================
+ Coverage 46% 46.36% +0.36%
- Complexity 26517 28037 +1520
============================================
Files 2614 2614
Lines 282790 288197 +5407
Branches 33598 33789 +191
============================================
+ Hits 130084 133614 +3530
- Misses 143430 144333 +903
- Partials 9276 10250 +974
Continue to review full report at Codecov.
|
Author
|
Fixed the formatting error. |
meltsufin
pushed a commit
that referenced
this pull request
Apr 29, 2026
meltsufin
pushed a commit
that referenced
this pull request
May 1, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Completes fix of #5227.
We found that the PubSub Subscriber can go into a thread creation loop when it fails on startup, eventually causing system-wide thread starvation. This PR fixes that problem by making sure that all background resources are also shut down on failure (instead of just when stopped).