Skip to content

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Aug 22, 2022

Backport of #74261 to release/6.0

/cc @tarekgh

Customer Impact

In Dependency Injection, when retrieving the IServiceProvider service and disposing it, it will not dispose the parent container which causes a memory leak. Users of HubConnection in SignalR already experienced and reported this issue as indicated in the issue #73832

Testing

Have passed all CI and regression tests. And manually confirmed it fixes the memory leak.

Risk

Fairly low risk. The change started to dispose the Service Provider object that is supposed to be disposed. The break here is minimal as no-one supposes to use this disposed object and even users can use this disposed object to create a Singlton service.

@ghost
Copy link

ghost commented Aug 22, 2022

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

Issue Details

Backport of #74261 to release/6.0

/cc @tarekgh

Customer Impact

Testing

Risk

IMPORTANT: Is this backport for a servicing release? If so and this change touches code that ships in a NuGet package, please make certain that you have added any necessary package authoring and gotten it explicitly reviewed.

Author: github-actions[bot]
Assignees: -
Labels:

area-Extensions-DependencyInjection

Milestone: -

@tarekgh tarekgh requested a review from eerhardt August 22, 2022 18:30
@tarekgh
Copy link
Member

tarekgh commented Aug 22, 2022

CC @davidfowl

@tarekgh tarekgh added the Servicing-consider Issue for next servicing release review label Aug 22, 2022
@tarekgh tarekgh self-assigned this Aug 22, 2022
@tarekgh tarekgh added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Aug 22, 2022
@tarekgh
Copy link
Member

tarekgh commented Aug 22, 2022

approved offline by @SteveMCarroll

@carlossanlop
Copy link
Contributor

carlossanlop commented Sep 7, 2022

Approved, signed off, OOB package authoring changes properly added, and the CI cannot get any greener than this. Ready to merge. :shipit:

@carlossanlop carlossanlop merged commit 84ea86c into release/6.0 Sep 7, 2022
@carlossanlop carlossanlop deleted the backport/pr-74261-to-release/6.0 branch September 7, 2022 20:03
carlossanlop added a commit to vseanreesermsft/runtime that referenced this pull request Oct 5, 2022
They were introduced in September in these 3 PRs:
- Microsoft.Extensions.DependencyInjection: dotnet#74366
- Microsoft.Extensions.Hosting.WindowsServices: dotnet#74188
- Microsoft.NETCore.Platforms (RIDs): dotnet#74383
carlossanlop added a commit that referenced this pull request Oct 5, 2022
* Update branding to 6.0.11

* Reseting OOB package authoring changes.
They were introduced in September in these 3 PRs:
- Microsoft.Extensions.DependencyInjection: #74366
- Microsoft.Extensions.Hosting.WindowsServices: #74188
- Microsoft.NETCore.Platforms (RIDs): #74383

Co-authored-by: Carlos Sanchez <[email protected]>
@ghost ghost locked as resolved and limited conversation to collaborators Oct 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants