Skip to content

chore(#458163,#458177): add net10.0 target framework and bump to 5.8.0#117

Open
mpKoczocik wants to merge 4 commits into
masterfrom
shared/core/212/chore/458177-ev-servicebus-net10-migration
Open

chore(#458163,#458177): add net10.0 target framework and bump to 5.8.0#117
mpKoczocik wants to merge 4 commits into
masterfrom
shared/core/212/chore/458177-ev-servicebus-net10-migration

Conversation

@mpKoczocik

Copy link
Copy Markdown
Collaborator

Summary

  • Adds net10.0 as an additional target framework alongside net8.0 (and netstandard2.0/netstandard2.1 on the two core packages) across all 7 packable src/ projects — non-breaking, existing net8.0 consumers unaffected
  • Samples move fully to net10.0 (dev-only, not published)
  • Tests multi-target net8.0;net10.0 where possible (UnitTests, HealthChecks.UnitTests, TestHelpers); AsyncApi.UnitTests/Mvc.UnitTests stay net10.0-only since they reference the now net10.0-only sample projects
  • Bumps Azure.Identity (1.17.0 was deprecated), Elastic.Apm, AspNetCore.HealthChecks.AzureServiceBus (and its Microsoft.Extensions.Diagnostics.HealthChecks floor to 8.0.11 to avoid a NU1605 downgrade error)
  • Bumps test tooling (Moq, Microsoft.NET.Test.Sdk, coverlet, FluentAssertions capped at 7.2.2 to avoid the v8+ commercial license, xunit kept on the v2 line)
  • Replaces Ev.ServiceBus.Mvc's legacy Microsoft.AspNetCore.Mvc.Abstractions/.Core 2.2.x package refs with a FrameworkReference to Microsoft.AspNetCore.App
  • Collapses the CI workflows' dead 3.1/5.0/6.0/8.0 SDK setup steps into a single .NET 10 setup step
  • Version bump to 5.8.0 (minor, non-breaking), CHANGELOG updated

Related: US #458163, Task #458177

Test plan

  • dotnet build — 0 errors
  • dotnet test — all pass across net8.0 and net10.0 (344 total test runs, 0 failures)

mpKoczocik and others added 3 commits July 21, 2026 15:12
…6.0.0

Retargets the two multi-targeted packages (Ev.ServiceBus, Ev.ServiceBus.Abstractions)
from netstandard2.1;netstandard2.0;net8.0 to netstandard2.1;netstandard2.0;net10.0,
and the five single-target packages (Apm, AsyncApi, HealthChecks, Mvc, Prometheus)
plus all tests/samples from net8.0 to net10.0. Keeps netstandard support unlike the
Ev.Idempotency precedent (US #446005) since this package has real external NuGet
consumers unlike Idempotency.

Bumps Azure.Identity (1.17.0 was deprecated), Microsoft.Extensions.* to 10.0.9,
Elastic.Apm, AspNetCore.HealthChecks.AzureServiceBus, and test tooling (Moq,
Microsoft.NET.Test.Sdk, coverlet, FluentAssertions capped at 7.2.2 to avoid the
v8+ commercial license, xunit kept on the v2 line). Replaces Ev.ServiceBus.Mvc's
legacy Microsoft.AspNetCore.Mvc.Abstractions/Core 2.2.x package refs with a
FrameworkReference to Microsoft.AspNetCore.App. Collapses the CI workflows' dead
3.1/5.0/6.0/8.0 SDK setup steps (nothing in the repo has targeted them for years)
into a single .NET 10 setup step. Fixes two FluentAssertions 7.x compile breaks
where StatusCodes.Status200OK (int) no longer implicitly compares against
HttpStatusCode via Should().Be().

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Reworks the previous commit per feedback: don't drop net8.0 from src/
projects, add net10.0 alongside it instead (non-breaking) - only samples
drop net8.0 (dev-only, not published). Tests multi-target net8.0;net10.0
where possible; AsyncApi.UnitTests and Mvc.UnitTests stay net10.0-only
since they reference the now net10.0-only sample projects.

Reverts the Microsoft.Extensions.* bump to 10.0.9 (no longer needed since
net8.0 stays) but bumps Microsoft.Extensions.Diagnostics.HealthChecks to
8.0.11 specifically - AspNetCore.HealthChecks.AzureServiceBus 9.0.0 requires
it, staying at 8.0.0 triggered a NU1605 downgrade error. Changes the version
bump from 6.0.0 to 5.8.0 (minor, non-breaking) and rewrites the CHANGELOG
entry accordingly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The UnitTests and HealthChecks.UnitTests projects multi-target
net8.0;net10.0, but the PR Gate workflow only set up the .NET 10 SDK -
collapsed too far when the tests were net10.0-only. dotnet test needs the
net8.0 runtime installed to launch the net8.0 test binaries ("You must
install or update .NET to run this application"), causing PR Gate run
29839325480 to fail on the Test step despite Build succeeding.
publish-nugets.yml doesn't run tests (build/pack/push only), so the .NET 10
SDK alone is sufficient there to build the net8.0 targets via restored
targeting packs - no equivalent fix needed.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

@benspeth benspeth left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

got 2 comments

Comment thread .github/workflows/publish-nugets.yml
Comment thread src/Ev.ServiceBus/Ev.ServiceBus.csproj Outdated
…ublish workflow

Addresses PR #117 review feedback from @benspeth:
- keep the .NET 8 SDK setup in publish-nugets.yml for now (was dropped when
  the workflow only needed net10.0)
- the net10.0-conditional Microsoft.Extensions.* package groups were still
  pinned at 8.0.0 (copy-pasted from the net8.0/netstandard2.1 groups) -
  bump them to 10.0.9, matching the platform-wide pin used by
  Shared.Notifications. Applied consistently to every sibling occurrence of
  the same pattern (Ev.ServiceBus, Ev.ServiceBus.Abstractions,
  Ev.ServiceBus.HealthChecks, Ev.ServiceBus.Prometheus), not just the one
  line flagged in review.

This creates a transitive requirement (Ev.ServiceBus's net10.0
Microsoft.Extensions.Logging 10.0.9 requires
Microsoft.Extensions.DependencyInjection >= 10.0.9), which surfaced two more
NU1605 downgrade errors in Ev.ServiceBus.TestHelpers and
Ev.ServiceBus.HealthChecks.UnitTests - both still referenced
Microsoft.Extensions.DependencyInjection unconditionally at 8.0.0. Split
those into net8.0/net10.0 conditional groups too.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@mpKoczocik
mpKoczocik marked this pull request as ready for review July 22, 2026 07:57
@ecofrankie

Copy link
Copy Markdown
Collaborator

AI Code Review — net10.0 migration

Overview: Adds net10.0 as an additional target framework across the 7 packable src/ projects (alongside net8.0, and netstandard2.0/netstandard2.1 on the two core packages), moves samples fully to net10.0, multi-targets most test projects, bumps several NuGet dependencies, replaces Ev.ServiceBus.Mvc's legacy MVC package refs with a FrameworkReference, trims dead CI SDK-setup steps, and bumps the package version to 5.8.0. Pure infra/packaging change — no library source logic touched.

Code Quality / Conventions

  • Good: FluentAssertions capped at 7.2.2 to avoid the v8+ commercial license.
  • Good: Ev.ServiceBus.Mvc.csproj replaces Microsoft.AspNetCore.Mvc.Abstractions/.Core 2.2.x package refs with <FrameworkReference Include="Microsoft.AspNetCore.App" /> — the correct modern pattern, since those 2.2.x packages predate the ASP.NET Core shared-framework model and wouldn't resolve cleanly against net10.0.
  • Good: Test files (DocumentFilterTest.cs, DispatchTest.cs) correctly swap Microsoft.AspNetCore.Http.StatusCodes for System.Net.HttpStatusCode — a necessary and clean consequence of dropping the direct MVC package reference.
  • Verified Ev.ServiceBus.csproj and Ev.ServiceBus.Abstractions.csproj — the new net10.0-conditioned ItemGroups don't collide with the existing net8.0/netstandard2.x groups (no duplicate-PackageReference risk).

Potential Issues

  • Minor description mismatch: the PR description says CI workflows collapse "3.1/5.0/6.0/8.0 SDK setup steps into a single .NET 10 setup step," but the diff keeps the .NET 8 setup step alongside the new .NET 10 step (only 3.1/5.0/6.0 were removed). Not a functional problem — just worth correcting the description.
  • Major version bumps worth a second look (mitigated by the passing test run, but flagging for awareness):
    • Scrutor 4.2.2 → 7.0.0 (3 major versions) — DI-scanning convention APIs have changed historically across that range. Worth a quick manual check of Scrutor usage in Ev.ServiceBus.UnitTests for renamed/removed fluent APIs if not already exercised by the passing suite.
    • AspNetCore.HealthChecks.AzureServiceBus 8.0.1 → 9.0.0 applied unconditionally across net8.0;net10.0 in Ev.ServiceBus.HealthChecks.csproj — relies on that package's own multi-targeting staying net8.0-compatible.
    • Aspire.AppHost.Sdk/Aspire.Hosting.AppHost 9.3.0 → 13.4.6 in the sample host — a large jump, but scoped to a dev-only, unpublished sample project.

Test Coverage

Test plan reports dotnet build clean and dotnet test green (344 runs, 0 failures) across net8.0/net10.0. Appropriate verification strategy for a pure packaging/TFM change.

Security

No security-sensitive code paths touched. Azure.Identity 1.17.0 → 1.17.1 addresses a deprecation warning, not a known CVE per the description.

Verdict

No blocking issues. Clean, well-scoped, low-risk migration PR. Suggested follow-ups: (1) fix the CI-workflow description line to match the actual diff, (2) optionally spot-check Scrutor v7 API usage given the 3-major-version jump.


Posted by an AI reviewer (Claude Code).

@benspeth benspeth self-assigned this Jul 22, 2026
@benspeth benspeth added the enhancement New feature or request label Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants