dotnet / dotnet/aspnetcore

Support HTTP/2 Dynamic Window Sizing in Kestrel

Open
#53,657 4 comments 0 reactions 0 assignees View on GitHub
area-networking feature-kestrel HTTP2
Dominant language
C#
Stars
38.4k
Forks
10.9k
Avg merge
2d 6h
Merged PRs (30d)
290

Description

### Is there an existing issue for this?

- [X] I have searched the existing issues

### Is your feature request related to a problem? Please describe the problem.

Kestrel specifies a static value for the [connection](https://learn.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.server.kestrel.core.http2limits.initialconnectionwindowsize?view=aspnetcore-8.0#microsoft-aspnetcore-server-kestrel-core-http2limits-initialconnectionwindowsize) and [stream](https://learn.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.server.kestrel.core.http2limits.initialstreamwindowsize?view=aspnetcore-8.0#microsoft-aspnetcore-server-kestrel-core-http2limits-initialstreamwindowsize) window sizes. We've already had to [increase](https://github.com/dotnet/aspnetcore/pull/43302) the defaults once.

### Describe the solution you'd like

Rather than increasing the defaults again (which consumes more resources and increase the risk of DoS), we should make the window size dynamic, as in [HttpClient](https://github.com/dotnet/runtime/pull/54755).

The window size should scale with the [bandwidth delay product](https://en.wikipedia.org/wiki/Bandwidth-delay_product) in order to be able accommodate fast connections with significant latency (e.g. transoceanic).

### Additional context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.