Skip to content

Commit

Permalink
Merge pull request #541 from hatoo/window-size
Browse files Browse the repository at this point in the history
[http2] set windows size to nghttp2's default
  • Loading branch information
hatoo authored Oct 26, 2024
2 parents 826d2b2 + 94c0224 commit a257f1b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,10 @@ impl Stream {
}
async fn handshake_http2(self) -> Result<SendRequestHttp2, ClientError> {
let mut builder = hyper::client::conn::http2::Builder::new(TokioExecutor::new());
builder.adaptive_window(true);
builder
// from nghttp2's default
.initial_stream_window_size((1 << 30) - 1)
.initial_connection_window_size((1 << 30) - 1);

match self {
Stream::Tcp(stream) => {
Expand Down

0 comments on commit a257f1b

Please sign in to comment.