[release-notes] ASP.NET Core in .NET 11 Preview 6#10456
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Adds the draft ASP.NET Core component release notes for .NET 11 Preview 6 to the release-notes repository, documenting new features, breaking changes, bug fixes, and community contributors for the milestone branch (release-notes/11.0-preview6).
Changes:
- Introduces feature writeups for Minimal API async validation, Blazor
Virtualizescrolling, OpenAPI updates,[ShortCircuit], and SignalR authentication refresh. - Captures notable breaking changes and a short bug-fix roundup.
- Adds a milestone-scoped community contributor list.
Verified each feature with runnable samples on the Preview 6 build: - Async validation: IAsyncValidatableObject also needs the sync Validate member, and AsyncValidationAttribute is overridden via IsValidAsync (not GetValidationResultAsync). - Virtualize: Items requires ICollection<T>, so the sample uses List<T> (IReadOnlyList<T> does not compile). - [ShortCircuit]: robots.txt should use [ShortCircuit] (200), not [ShortCircuit(404)] which returns the body with a 404; added a minimal API example. OpenAPI 3.2 default + union anyOf schema and SignalR auth refresh verified accurate as written. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Verified every feature in these notes by building and running samples against the locally installed .NET 11 Preview 6 SDK (build Async validation (ran a minimal API; valid → 200, async rules → 400):
Blazor Virtualize (verified in a headless browser:
Verified accurate as written (no change):
Note: the local build is |
…59.118 - Rename async validation section to 'Async validation for minimal APIs' (danroth27); cross-reference the libraries release notes; throw from the sync Validate for async-only types (Youssef1313). - Split OpenAPI into 'OpenAPI 3.2 by default' (kept as a feature) and a broader 'Unions in ASP.NET Core' section covering Minimal APIs, MVC, SignalR, and Blazor, with cross-references to the C#/libraries notes (BrennanConroy). Shorter headings (Copilot). - SignalR: add the client-side WithAuthenticationRefresh API, and a new 'Cancel hub invocations from the client' section for #64098 (BrennanConroy). - Community contributors: remove Microsoft/.NET-team affiliated accounts. Verified every sample against the final Preview 6 SDK (11.0.100-preview.6.26359.118). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Pushed an update addressing the review feedback. Summary: Restructure
Re-verified on the final Preview 6 build ( Community contributors — vetted all 12 for Microsoft/.NET-team affiliation and removed two:
The other 10 (Xebia, Syncfusion, IBM, Cloudflare, and independents) are external and were kept. @desjoerd and @sheiksyedm are public members of the |
Neither is on the .NET product team (per danroth27), so they belong in the community contributors list even though one is a Microsoft employee (other team) and one is a vendor contractor. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Verified each against the final Preview 6 build (26359.118) with samples: - Automatic cross-origin (CSRF) protection (#66585) — auto-enabled; the main feature behind the existing #67082 breaking-change note. - Configure browser behavior from the server / WithBrowserOptions (#67337). - EnvironmentView + NavigationManager.GetUriWithFragment (#67369, #67368). - dotnet user-jwts --file for file-based apps (#66919). - Bug fixes: WebView Hybrid @rendermode no-op (#65876); QUERY hosting metric (#63276). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Evaluated the 12 PRs against the final Preview 6 build ( Added (verified in the build):
Already documented: #66753 (Virtualize), #64098 (hub-invocation cancellation). Excluded (with reason):
Two API-shape notes worth flagging (found by building samples, not from PR bodies): |
…ng changes - Move EnvironmentBoundary->EnvironmentView, GetUriWithHash->GetUriWithFragment, browser options reshape, media component move, and the minimal API validation resolver split into a new 'Preview API changes' section (migration notes). - Remove the two Blazor feature sections that re-documented renamed APIs. - Document automatic cross-origin (CSRF) protection as new functionality (fold in the shared-verdict detail from #67082) instead of a breaking change. - Reference the Preview 1 EnvironmentBoundary notes for the rename. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Reframed the Blazor preview API changes per the guidance that preview-to-preview renames aren''t breaking changes (we haven''t shipped these APIs in a stable release yet). New
Removed the two Blazor feature sections that re-documented the renamed APIs — we don''t need to re-document a renamed feature, just note the rename. Automatic cross-origin (CSRF) protection is now documented purely as new functionality; I folded the shared-verdict detail (dotnet/aspnetcore#67082) into that feature section instead of listing it as a breaking change. Net result: there is no
|
The Microsoft.AspNetCore.Components.Media package has no matching preview.6 build, so drop the media-components mention for now. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
… links Verified against the .NET 11 Preview 6 source (release/11.0.1xx-preview6) and the installed 26359.118 build: - CORS-policy trust for cross-origin callers (the primary upgrade action) - .DisableAntiforgery() / [IgnoreAntiforgeryToken] per-endpoint opt-out and the DisableCsrfProtection global key - clarify verdict is deferred to form consumers (JSON APIs aren't rejected) - correct middleware ordering to 'after authentication and authorization' - link the new conceptual and migration docs Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Reviewed the Automatic cross-origin (CSRF) protection section against the new draft docs (reference, migration) and improved it. Every claim is verified against the Preview 6 source ( What changed:
Runtime check against the installed P6 build (curl,
One nuance worth knowing: reading |
Release notes should introduce the feature, not reproduce docs content. Remove the CORS/opt-out how-to and the doc links (docs may be refactored). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep the per-endpoint and global opt-out options and the ICsrfProtection extension point (verified in the P6 source); drop only the how-to detail and doc links. Trim the now-redundant opt-out clause from the intro. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Apply BrennanConroy's review suggestions on PR #10456. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
|
||
| ## Async validation for minimal APIs | ||
|
|
||
| Minimal API validation now supports asynchronous validators end-to-end ([dotnet/aspnetcore #66487](https://github.com/dotnet/aspnetcore/pull/66487), [dotnet/aspnetcore #67183](https://github.com/dotnet/aspnetcore/pull/67183)). Preview 5 shipped the building blocks for asynchronous form validation in Blazor. Preview 6 adds the new asynchronous `DataAnnotations` APIs in the base libraries — `AsyncValidationAttribute`, `IAsyncValidatableObject`, and `Validator.ValidateObjectAsync` — and `Microsoft.Extensions.Validation` now runs them when an endpoint validates a request. The new base-library APIs are covered in the [.NET libraries release notes](./libraries.md#asynchronous-validation-with-dataannotations). |
There was a problem hiding this comment.
fwiw, Validator class isn't used by Microsoft.Extensions.Validation at all. It's only used by Blazor when Microsoft.Extensions.Validation isn't wired up.
|
|
||
| Minimal API validation now supports asynchronous validators end-to-end ([dotnet/aspnetcore #66487](https://github.com/dotnet/aspnetcore/pull/66487), [dotnet/aspnetcore #67183](https://github.com/dotnet/aspnetcore/pull/67183)). Preview 5 shipped the building blocks for asynchronous form validation in Blazor. Preview 6 adds the new asynchronous `DataAnnotations` APIs in the base libraries — `AsyncValidationAttribute`, `IAsyncValidatableObject`, and `Validator.ValidateObjectAsync` — and `Microsoft.Extensions.Validation` now runs them when an endpoint validates a request. The new base-library APIs are covered in the [.NET libraries release notes](./libraries.md#asynchronous-validation-with-dataannotations). | ||
|
|
||
| This lets a validation rule do real work, such as a database lookup or a remote API call, without blocking a thread. A model implements `IAsyncValidatableObject` and returns validation results as an `IAsyncEnumerable<ValidationResult>`. Because `IAsyncValidatableObject` extends `IValidatableObject`, also implement the synchronous `Validate` method. When a type validates asynchronously only, throw from `Validate` so it isn't silently validated through the synchronous APIs: |
There was a problem hiding this comment.
Should this say "isn't silently skipped"?
|
|
||
| // IValidatableObject (synchronous) — this type validates asynchronously only. | ||
| public IEnumerable<ValidationResult> Validate(ValidationContext context) => | ||
| throw new NotSupportedException("Validate this type with ValidateAsync."); |
There was a problem hiding this comment.
The docs suggest InvalidOperationException instead of NotSupportedException.
|
|
||
| ## OpenAPI 3.2 by default | ||
|
|
||
| Generated OpenAPI documents now target OpenAPI 3.2 by default ([dotnet/aspnetcore #67097](https://github.com/dotnet/aspnetcore/pull/67097), [dotnet/aspnetcore #67007](https://github.com/dotnet/aspnetcore/pull/67007)). OpenAPI 3.2 is the newest version of the specification. Documents continue to generate as before; set the document version explicitly if you need to target an earlier version for tooling that hasn't adopted 3.2 yet. |
There was a problem hiding this comment.
I'm having a hard time understanding what "Documents continue to generate as before" means
There was a problem hiding this comment.
Pinging @tdykstra for an 👁️ on this suggestion because we're mirroring this language in the PR for ASP.NET Core What's New coverage (dotnet/AspNetCore.Docs #37334).
Youssef1313
left a comment
There was a problem hiding this comment.
LGTM for the parts in my areas. Only left few comments.
Also are we intentionally missing dotnet/aspnetcore#66527 ?
Draft ASP.NET Core release notes for .NET 11 Preview 6. This PR targets the milestone base branch
release-notes/11.0-preview6(see #10455).Please review the AI-authored content for accuracy, including any code samples and
<!-- TODO -->/<!-- Filtered features -->notes, then mark ready for review. 🤖 Generated with the release-notes skill.