Skip to content

Comments

Make MaxRequestBodySize configurable #1947

Merged
Tratcher merged 2 commits intomainfrom
tratcher/bodysize
Dec 2, 2022
Merged

Make MaxRequestBodySize configurable #1947
Tratcher merged 2 commits intomainfrom
tratcher/bodysize

Conversation

@Tratcher
Copy link
Member

@Tratcher Tratcher commented Dec 1, 2022

Fixes #640

The servers all have a configurable MaxRequestBodySize limit that defaults to ~30MB. This can be overridden per request with a feature. The most common case is to raise it for certain endpoints that upload big files, or to disable it for streaming scenarios. Some scenarios automatically disable it like WebSockets or gRPC streaming. Others need to be configured.

There is .NET 8 work planned to centralize this into endpoint metadata and middleware, but we want to support this for 6 and 7 in the meantime. dotnet/aspnetcore#40452

@Tratcher Tratcher added this to the YARP 2.0.0 milestone Dec 1, 2022
@Tratcher Tratcher self-assigned this Dec 1, 2022
@Tratcher Tratcher requested a review from MihaZupan as a code owner December 1, 2022 22:52
@Tratcher Tratcher mentioned this pull request Dec 1, 2022
@Tratcher Tratcher enabled auto-merge (squash) December 2, 2022 19:45
@Tratcher Tratcher merged commit 7cef5f2 into main Dec 2, 2022
@Tratcher Tratcher deleted the tratcher/bodysize branch December 2, 2022 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Request body too large

2 participants