-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Hot reload script injection improvements #27537
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
Merged
MackinnonBuck
merged 7 commits into
release/7.0.1xx
from
mbuck/7.0.1xx/hot-reload-script-injection-improvements
Sep 1, 2022
Merged
Hot reload script injection improvements #27537
MackinnonBuck
merged 7 commits into
release/7.0.1xx
from
mbuck/7.0.1xx/hot-reload-script-injection-improvements
Sep 1, 2022
Conversation
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
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
javiercn
approved these changes
Aug 30, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
This was referenced Oct 20, 2022
MackinnonBuck
added a commit
that referenced
this pull request
Nov 21, 2022
This reverts commit 7d4ae9a.
mkArtakMSFT
pushed a commit
that referenced
this pull request
Jan 4, 2023
…ng (#29152) ## Summary Fixes a regression in memory consumption caused by large responses when debugging with hot reload enabled. ## Description As one of the changes introduced in .NET 7 by #27537, the hot reload script injection middleware now buffers the entire response before performing script injection. This was done to improve script injection reliability, but we recently began receiving reports from customers that were confused by the increase in server memory usage for large responses when debugging with hot reload is enabled. This PR reverts the buffering behavior but keeps the logging improvements that help customers identify the cause of script injection failures and take steps to fix them. For .NET 8, we will assess an alternative approach to improve script injection reliability that doesn't involve buffering each response. ## Validation Manual validation + existing automated tests for this scenario. ## Risk Low. This PR simply reverts the offending commit and adds back some of the improved logging behavior with no other changes to functionality. Fixes dotnet/aspnetcore#45037
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.
Hot reload script injection improvements
Summary
Improved hot reload script injection to be more reliable and provide better log messages when failure occurs.
Description
Implemented the following improvements to hot reload script injection:
Content-Encoding
header exists.Fixes dotnet/aspnetcore#41772