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

[release/6.0] Reduce net core app current package dependencies, increase direct update availability #108797

Merged
merged 9 commits into from
Oct 14, 2024

Conversation

ericstj
Copy link
Member

@ericstj ericstj commented Oct 11, 2024

Customer Impact

  • Customer reported
  • Found internally

Customers using packages like Microsoft.Extensions.Logging.Console, System.Memory.Data, Microsoft.Extensions.Hosting, etc and targeting net6.0 need to update package references for packages like System.Text.Json, System.Text.Encodings.Web, System.Collections.Immutable, etc even though those libraries are provided by the shared framework.

We can reduce the number of places where folks need to update packages by omitting packages when the same library is provided by the framework.

Additionally we've shipped many packages over the course of net6.0 but haven't shipped every package that depends on them - causing customers to update more transitive dependencies to get updates. We have seen slower up-take for security fixes when transitive updates are required - the goal here is to ensure more direct updates are available.

Regression

  • Yes
  • No

Testing

Build packages. Add validation to make sure all up-stack packages ship as well. Examined package diffs.

Risk

Low. This is removing package references for a few packages and enabling more packages. The biggest risk here is that we'll be enabling a lot of packages that need to flow in servicing - a total of 55 - but the goal here is that this set of packages will help customers better get clean of CVEs.

Background

This drops package dependencies from all packages which can reference the framework copy of the same library (without downgrading the library exposed to a compatible TFM like netstandard2.0).

I also added a feature to our build that enforces transitive servicing. You can specify ServiceTransitiveDependencies to make sure that you enable all up-stack packages for shipping when enabling a single package.

I enabled all packages I changed, then all upstack packages (separate commits).

This should improve the situation where folks are asked to update just to update a package reference on the latest framework.

It will also help reduce application size since the libraries will no longer be bundled in the app.

PR detail

This is a backport of #107161.

I also reviewed all packages that ever shipped in 6.0 with a CVE to ensure that we've shipped at least one package version that references that - to ensure folks have availability of a direct update for the CVE.

The only "code changes" in this PR are to remove dependencies when the same dependency is in the shared framework. You can see the result of that diff here: ericstj/diffs@499919a

The remaining changes are infrastructure or enabling packages.

…an avoid these dependencies since we can count on the library being part of the shared framework. Fewer dependencies means less packages downloaded, less for customers to service, less copied into the output directory when serviced.��Backport of 6e440de
Copy link
Contributor

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

@teo-tsirpanis teo-tsirpanis added this to the 6.0.x milestone Oct 11, 2024
@ericstj ericstj changed the title Reduce net core app current package dependencies, increase direct update availability [release/6.0] Reduce net core app current package dependencies, increase direct update availability Oct 11, 2024
Copy link
Member

@carlossanlop carlossanlop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just a couple of optional nits.
I'll write down the list of enabled OOB packages.

Co-authored-by: Carlos Sánchez López <[email protected]>
@ericstj
Copy link
Member Author

ericstj commented Oct 14, 2024

Lots of System.IO.Tests failures here which appear to be #100558 but it's not being linked.

@carlossanlop
Copy link
Member

How's this looking @ericstj? Friendly reminder that today 10/14 is Code Complete for the November Release.

@ericstj ericstj added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Oct 14, 2024
@ericstj
Copy link
Member Author

ericstj commented Oct 14, 2024

Approved over email.

@ericstj
Copy link
Member Author

ericstj commented Oct 14, 2024

This needs to resolve conflicts with #108675

@ericstj
Copy link
Member Author

ericstj commented Oct 14, 2024

@carlossanlop - Ok, this had some churn with resolving conflicts, but it should be ready to go. The tests failing earlier were all known issues but BA gave up with too many wasm failures.

@ericstj
Copy link
Member Author

ericstj commented Oct 14, 2024

Both all configurations legs which build packages have completed. Going to merge this to get the 6.0 servicing release moving

@ericstj ericstj merged commit ba80929 into dotnet:release/6.0-staging Oct 14, 2024
135 of 155 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Nov 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants