This repository was archived by the owner on Mar 4, 2026. It is now read-only.
Don't call stream.end() on Watch ended by server#565
Merged
schmidt-sebastian merged 2 commits intomasterfrom Mar 5, 2019
Merged
Don't call stream.end() on Watch ended by server#565schmidt-sebastian merged 2 commits intomasterfrom
schmidt-sebastian merged 2 commits intomasterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #565 +/- ##
==========================================
- Coverage 95.85% 95.77% -0.08%
==========================================
Files 24 24
Lines 1931 1943 +12
Branches 168 168
==========================================
+ Hits 1851 1861 +10
- Misses 57 59 +2
Partials 23 23
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #565 +/- ##
==========================================
+ Coverage 95.85% 95.88% +0.02%
==========================================
Files 24 24
Lines 1931 1943 +12
Branches 168 168
==========================================
+ Hits 1851 1863 +12
Misses 57 57
Partials 23 23
Continue to review full report at Codecov.
|
JustinBeckwith
approved these changes
Mar 5, 2019
Contributor
Author
|
I'm gonna leave this unmerged for a bit to give @mikelehen a chance to comment. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This is part of #564
The changes in #564 to make
formattedName()async changed a lot of the timing in the Watch code and uncovered an issue with the way we close streams. We should only callstream.end()if the SDK closes the stream. If the server closes the stream we don't call end() - if we do, we get an exception (that was previously swallowed).This PR also introduces subclasses for Watch that provide the Target Proto and the Comaprator. This makes it possible to construct these after initialization time and to return a Promise.