-
Notifications
You must be signed in to change notification settings - Fork 183
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle HTTP/1.1 response cancelation same way at all levels (#2266)
Motivation: When response cancel is generated at the client level, `LoadBalancedStreamingHttpClient` has a logic in place to close the connection to mitigate a race between connection availability and closure. However, this logic is skipped if cancellation is originated from a connection-level filter. Modifications: - Move cancellation handling from `LoadBalancedStreamingHttpClient` to `AbstractStreamingHttpConnection`; - Propagate `OnStreamClosedRunnable` using `request.context()`; - Remove `StreamingHttpRequestWithContext`; - Remove "cancel handling" logic from `TimeoutHttpRequesterFilter` introduced in #2263; - Add more comments and javadoc; - Adjust tests and comments; Result: Request to cancel is intercepted after all user-defined filters to make sure we catch all sources of cancellation.
- Loading branch information
1 parent
da06991
commit 4bae4c1
Showing
11 changed files
with
180 additions
and
645 deletions.
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
Oops, something went wrong.