fix(volo-http): return reusable HTTP/1 connections from the driver - #663
Open
junliurs wants to merge 1 commit into
Open
fix(volo-http): return reusable HTTP/1 connections from the driver#663junliurs wants to merge 1 commit into
junliurs wants to merge 1 commit into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #663 +/- ##
==========================================
+ Coverage 50.23% 50.90% +0.66%
==========================================
Files 163 163
Lines 20588 20891 +303
==========================================
+ Hits 10342 10634 +292
- Misses 10246 10257 +11 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Joshuahoky
reviewed
Aug 13, 2026
| B::Error: Into<BoxError> + 'static, | ||
| { | ||
| #[cfg(feature = "http1")] | ||
| let key = (peer.scheme.clone(), peer.address.clone()); |
Contributor
There was a problem hiding this comment.
When __tls is enabled, PeerInfo::name contains the TLS SNI/service name, but PoolKey only contains (Scheme, Address). This means two HTTPS connections to the same IP but with different SNI names can collide in the connection pool and a connection established for one hostname may be reused for another. The PoolKey should include the TLS server name:
#[cfg(feature = "__tls")]
type PoolKey = (Scheme, Address, Option<faststr::FastStr>);
#[cfg(not(feature = "__tls"))]
type PoolKey = (Scheme, Address);
shenyj3
reviewed
Aug 13, 2026
|
|
||
| // 5. The response body or request flush is still in progress. Wait for | ||
| // the next connection wakeup. | ||
| if !returned.http_sender.is_ready() { |
junliurs
force-pushed
the
fix/http1-managed-connection-reuse
branch
2 times, most recently
from
August 13, 2026 10:19
229c223 to
7f468e0
Compare
Move the HTTP/1 sender between the pool, request future, and connection driver through a return channel. Reinsert the connection only after Hyper reports it ready, while preserving cancellation safety and the existing response body fast path.
junliurs
force-pushed
the
fix/http1-managed-connection-reuse
branch
from
August 13, 2026 12:32
7f468e0 to
5cc45b3
Compare
shenyj3
approved these changes
Aug 14, 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.
Move the HTTP/1 sender between the pool, request future, and connection driver through a return channel. Reinsert the connection only after Hyper reports it ready, while preserving cancellation safety and the existing response body fast path.
Motivation
Solution