The Wayback Machine - https://web.archive.org/web/20210510232011/https://github.com/dotnet/runtime/pull/52572
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trim some HttpHeader parsing logic on browser-wasm #52572

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

@eerhardt
Copy link
Member

@eerhardt eerhardt commented May 10, 2021

Introduce a new feature switch: System.Net.Http.MinimalHeaderValidation. When set to true, this switch will allow for trimming header parsing logic that may not be needed in the app.

Contributes to #44534

Before: 2,644,974 bytes
After: 2,640,488 bytes (with new feature switch set)

So roughly 4.5KB .br compressed savings in a Blazor WASM app. Opening this PR as "draft" to get feedback on the approach. I'm not convinced this savings is worth the tradeoff. Can anyone think of more header parsers that could be removed with the proposed feature switch?

cc @CoffeeFlux @marek-safar

Introduce a new feature switch: System.Net.Http.MinimalHeaderValidation. When set to `true`, this switch will allow for trimming header parsing logic that may not be needed in the app.

Contributes to #44534
@msftbot
Copy link
Contributor

@msftbot msftbot bot commented May 10, 2021

Tagging subscribers to this area: @dotnet/ncl
See info in area-owners.md if you want to be subscribed.

Issue Details

Introduce a new feature switch: System.Net.Http.MinimalHeaderValidation. When set to true, this switch will allow for trimming header parsing logic that may not be needed in the app.

Contributes to #44534

Before: 2,644,974 bytes
After: 2,640,488 bytes (with new feature switch set)

So roughly 4.5KB .br compressed savings in a Blazor WASM app. Opening this PR as "draft" to get feedback on the approach. I'm not convinced this savings is worth the tradeoff. Can anyone think of more header parsers that could be removed with the proposed feature switch?

cc @CoffeeFlux @marek-safar

Author: eerhardt
Assignees: -
Labels:

area-System.Net.Http

Milestone: -
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
1 participant