Repository navigation
fix(streaming): preserve receive credit after call completion - #824
Merged
Merged
Conversation
4 of 13 tasks
SunSi12138
marked this pull request as ready for review
October 11, 2026 09:24
This was referenced Oct 11, 2026
SunSi12138
added a commit
that referenced
this pull request
Oct 11, 2026
SunSi12138
added a commit
that referenced
this pull request
Oct 11, 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.
Summary
Extracts the reproduced Terminal Stream Credit correctness fix from #754 onto current dev
6f19cd0cfd1bde4a4911bf59c413205d4ce93cd4(#810 and #814–#816 included).A queued OneWay failure can leave its completed call state mapped while an exception mapper runs. The receive loop previously skipped later stream frames before accounting them, permanently losing sender credit. The deterministic regression holds the mapper, publishes a 64-byte window and fences the same connection before checking that credit is restored.
Scope and invariants
This is a 14-file standalone change: seven production files, four focused regression files, two documentation files and removal of one obsolete maintainability exception. Public API snapshots, IRpcStub/descriptor contracts, generated ABI identity/version, generator code, outbound snapshot tracking and wire format are unchanged. #754 remains a separate reference; its MethodShape optimization is not included.
Validation
Current production head:
e4fa38555677b5693a77a4a3b94722f7c4361f04, tree80952edab6704b312fe0fe9bf67a93fc34f85320, based on actual dev6f19cd0cfd1bde4a4911bf59c413205d4ce93cd4.Independent source review approved the extraction and subsequent clean merge, preserving all #810/#815/#816 cleanup deletions. Public API, generated contracts, identity and outbound method snapshots have zero delta against dev.
Final standalone exact-source validation passed on
e4fa3855, against actual dev6f19cd0c:The maintainability gate initially detected two extra lines in an existing oversized file. Its unchanged OneWay completion helper was moved into a focused partial, bringing the original file below the normal threshold; the now-obsolete exception was removed rather than increased. The baseline-proof parser was adapted to TUnit's actual error-element format while retaining exact assertion, test identity and stack provenance requirements.
Fast, package smoke and CodeQL also passed on the final head. Both exact-source canonical PR Extended and formal PR Extended passed. The formal tested merge-ref tree is identical to the candidate tree. Extended includes the Debug rollback test, all 454 integration tests, source NativeAOT, packaged consumers, demo/load validation and six-platform desktop codec compatibility (2,088 compatible results); eight browser jobs retain their canonical conditional skips. Prior #754 results are not used as acceptance evidence for this extraction.
Regression coverage includes original-byte totals, buffered credit, absent/live routes, malformed compressed lengths, terminal transitions during decode/failure, duplicate frames, exact route replacement and stale pooled generations.
No performance claim or snapshot redesign is included. Merge is conditional on the final integration and latest-dev checks passing.