-
Notifications
You must be signed in to change notification settings - Fork 159
Stream endpoint #253
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
Merged
Merged
Stream endpoint #253
Conversation
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
a25259a to
8a08b57
Compare
228cf0c to
533d87b
Compare
533d87b to
ee78cd4
Compare
tonybase
approved these changes
Oct 20, 2025
In bidirectional streaming (HTTP/2, WebSocket), OnFinish callbacks should only execute when both request and response bodies are closed, not when each body closes individually. Changes: - Add body tracking to MetaStreamContext with atomic counters - Register each wrapped body and track closure count - Execute OnFinish only when all registered bodies are closed - Skip wrapping WebSocket request bodies (data flows through response body) - Remove unused Index field from MetaStreamChunk 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Simplify OnFinish callback signature by removing unused tag parameter - Add Err field to MetaStreamChunk for error propagation in stream hooks - Fix resource leak by deferring request body close in stream endpoints 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
http.ErrAbortHandler is a sentinel error used by httputil.ReverseProxy to signal intentional connection termination. Previously, this was caught by the panic handler and treated as an error, returning 502. Now it's properly recognized and silently handled. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
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.
No description provided.