-
Notifications
You must be signed in to change notification settings - Fork 10.3k
[automated] Merge branch 'release/2.1' => 'release/3.1' #24375
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
[automated] Merge branch 'release/2.1' => 'release/3.1' #24375
Conversation
There are two places in 2.1 where SendFileAsync falls back to a copy loop. These loops should short circuit when the client disconnects, or else the server will sit there and burn resources reading the whole file from disk. Fix: If you passed in your own active CT we'll use it. Otherwise we'll use the RequestAborted token.
This is the 3.1 version of https://dev.azure.com/dnceng/internal/_git/dotnet-aspnetcore/pullrequest/9014. The concerns in 3.1 are slightly different than prior versions due to a significant redesign in how the response body was handled. In 2.1 very few components implemented IHttpSendFileFeature, and most of those that did would eagerly terminate if the request aborted (e.g. HttpSys server). We mainly had to be concerned about the fallback code that did a copy loop when IHttpSendFileFeature wasn't available. In 3.x the response body Stream, PipeWriter, and SendFileAsync were consolidated onto the new IHttpResponseBodyFeature. Now all servers and component shims support all three ways to send data and we can't make any assumptions about how eagerly they terminate. E.g. many components implemented SendFileAsync using a fallback copy loop, and these components don't have access to RequestAborted to eagerly terminate. This means that in 3.1 we need to pass the RequestAborted token when calling IHttpSendFileFeature.SendFileAsync, as well as any copy loops that have access to the token. I've primarily fixed the HttpResponse.SendFileAsync extension methods and made sure the other affected components call through here. [Infrastructure side note] This commit needs to be rebased on internal/release/3.1 before merging. That branch can't be built locally so I developed this fix based on release/3.1 instead.
The 3.1 PR builds aren't working so I missed some new test failures caused by my prior change. https://dev.azure.com/dnceng/internal/_build/results?buildId=734369&view=ms.vss-test-web.build-test-results-tab HttpSys has some odd behavior when you call SendFileAsync multiple times on an aborted response. The first time throws an OperationCancelledException, but the second time throws an ObjectDisposedException. This only happens if you enable HttpSysOptions.ThrowWriteExceptions and pass in a cancelled token. https://github.com/dotnet/aspnetcore/blob/472fc5058ecbddd4cd546a40628ec5a0545b8125/src/Servers/HttpSys/src/RequestProcessing/ResponseBody.cs#L577 I'm not aware of any scenarios where SendFileAsync is called multiple times like this, so for now I'm only fixing up the tests.
Create the GCHandle per operation and Free it when resetting the ValueTaskSource for re-use.
…g/internal/dotnet-aspnetcore-tooling This pull request updates the following dependencies [marker]: <> (Begin:7bf32a0c-3505-43af-42b0-08d79559e63d) ## From https://dev.azure.com/dnceng/internal/_git/dotnet-aspnetcore-tooling - **Subscription**: 7bf32a0c-3505-43af-42b0-08d79559e63d - **Build**: 20200721.7 - **Date Produced**: 7/22/2020 4:18 AM - **Commit**: 1c22292bc7fca352074d8862cf39fbdb8647f208 - **Branch**: refs/heads/internal/release/3.1 - **Updates**: - **Microsoft.AspNetCore.Razor.Language**: from 3.1.6 to 3.1.7 - **Microsoft.CodeAnalysis.Razor**: from 3.1.6 to 3.1.7 - **Microsoft.NET.Sdk.Razor**: from 3.1.6 to 3.1.7 - **Microsoft.AspNetCore.Mvc.Razor.Extensions**: from 3.1.6 to 3.1.7 [marker]: <> (End:7bf32a0c-3505-43af-42b0-08d79559e63d)
…g/internal/dotnet-efcore This pull request updates the following dependencies [marker]: <> (Begin:Coherency Updates) ## Coherency Updates The following updates ensure that dependencies with a *CoherentParentDependency* attribute were produced in a build used as input to the parent dependency's build. See [Dependency Description Format](https://github.com/dotnet/arcade/blob/master/Documentation/DependencyDescriptionFormat.md#dependency-description-overview) [DependencyUpdate]: <> (Begin) - **Coherency Updates**: - **Microsoft.AspNetCore.Analyzer.Testing**: from 3.1.6-servicing.20316.5 to 3.1.7-servicing.20371.8 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.AspNetCore.BenchmarkRunner.Sources**: from 3.1.6-servicing.20316.5 to 3.1.7-servicing.20371.8 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.ActivatorUtilities.Sources**: from 3.1.6-servicing.20316.5 to 3.1.7-servicing.20371.8 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Caching.Abstractions**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Caching.Memory**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Caching.SqlServer**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Caching.StackExchangeRedis**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.CommandLineUtils.Sources**: from 3.1.6-servicing.20316.5 to 3.1.7-servicing.20371.8 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.Abstractions**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.AzureKeyVault**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.Binder**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.CommandLine**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.EnvironmentVariables**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.FileExtensions**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.Ini**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.Json**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.KeyPerFile**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.UserSecrets**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration.Xml**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.Configuration**: from 3.1.6 to 3.1.7 (parent: Microsoft.EntityFrameworkCore) - **Microsoft.Extensions.DependencyInjection.Abstractions**: from ...
8691921
to
94076d4
Compare
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.
Auto-approving branch merge.
Hello @msftbot[bot]! Because this pull request has the Do note that I've been instructed to only help merge pull requests of this repository that have been opened for at least 60 minutes. No worries though, I will be back when the time is right! 😉 p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
Blocked until release/3.1 branches are next open |
- build targeting pack to pick up NuGet/Home#8599 fix - dotnet/extensions#2750 and dotnet#24200 2/2 - requires follow-up after next official extensions build - fake the baseline update - remainder must be done after the 3.1.7 release
Update branding to 3.1.8
- ports 522088b to this branch
Update branding to 2.1.22
This pull request has been updated. This PR merges commits made on release/2.1 by the following committers: |
@dougbu is this unblocked aside from the normal merge conflicts? |
Yes, no longer blocked |
# Conflicts: # build/sources.props # eng/Baseline.Designer.props # eng/Baseline.xml # eng/PatchConfig.props # modules/EntityFrameworkCore # src/AzureIntegration/build/repo.targets # src/AzureIntegration/build/sources.props # src/AzureIntegration/test/Microsoft.AspNetCore.AzureAppServices.FunctionalTests/Assets/NuGet.latest.config # src/Http/Http.Extensions/src/SendFileResponseExtensions.cs # src/Http/Http.Extensions/test/testfile1kb.txt # src/Http/HttpAbstractions.sln # src/Installers/Windows/AspNetCoreModule-Setup/ANCMPackageResolver/ANCMPackageResolver.csproj # src/Middleware/Middleware.sln # src/Middleware/ResponseCompression/src/BodyWrapperStream.cs # src/Middleware/ResponseCompression/test/BodyWrapperStreamTests.cs # src/Templating/build/sources.props # test/Cli.FunctionalTests/NuGetPackageSource.cs # version.props
Did I screw up the merge? I'm not sure why it's showing 3.1 changes in the diff. |
❌ Uh oh, this pull request could not be updated automatically. New commits were pushed to release/2.1, but I could not automatically push those to merge/release/2.1-to-release/3.1 to update this PR. |
I detected changes in the release/2.1 branch which have not been merged yet to release/3.1. I'm a robot and am configured to help you automatically keep release/3.1 up to date, so I've opened this PR.
This PR merges commits made on release/2.1 by the following committers:
Instructions for merging from UI
This PR will not be auto-merged. When pull request checks pass, complete this PR by creating a merge commit, not a squash or rebase commit.
If this repo does not allow creating merge commits from the GitHub UI, use command line instructions.
Instructions for merging via command line
Run these commands to merge this pull request from the command line.
or if you are using SSH
After PR checks are complete push the branch
Instructions for resolving conflicts
Instructions for updating this pull request
Contributors to this repo have permission update this pull request by pushing to the branch 'merge/release/2.1-to-release/3.1'. This can be done to resolve conflicts or make other changes to this pull request before it is merged.
or if you are using SSH
Contact .NET Core Engineering if you have questions or issues.
Also, if this PR was generated incorrectly, help us fix it. See https://github.com/dotnet/arcade/blob/master/scripts/GitHubMergeBranches.ps1.