Skip to content

Commit 801b9b3

Browse files
Copilotwadepickettdanroth27
authored
Add rate-limiting RetryAfter fixes to What's New for .NET 11 Preview 4 (#37151)
* Initial plan * Add rate-limiting fixes include file for preview4 Agent-Logs-Url: https://github.com/dotnet/AspNetCore.Docs/sessions/ff6f5db4-b8a9-4897-bae7-31d2ce227450 Co-authored-by: wadepickett <10985336+wadepickett@users.noreply.github.com> * Add code sample from source release notes to rate-limiting include file Agent-Logs-Url: https://github.com/dotnet/AspNetCore.Docs/sessions/ec595e41-7255-4739-a28b-d3514c2caf95 Co-authored-by: wadepickett <10985336+wadepickett@users.noreply.github.com> * Apply suggestion from @wadepickett Removing cross-link until <xref:System.Threading.RateLimiting.ChainedRateLimiter%601> is avaialble in API ref build. * Update rate-limiting-retry-after-preview4.md Removing code snippet per review suggestion. It is not relevant to the ASP.NET Core rate limiting middleware scenario. * Rename include file to rate-limiting-retry-after-preview-4.md and update reference Agent-Logs-Url: https://github.com/dotnet/AspNetCore.Docs/sessions/4542cc0b-fadf-40e6-8735-4156936fe239 Co-authored-by: wadepickett <10985336+wadepickett@users.noreply.github.com> * Apply suggestion from @danroth27 Co-authored-by: Daniel Roth <daroth@microsoft.com> * Apply suggestion from @wadepickett * Apply suggestion from @wadepickett Fix per gewarren review suggestion. --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: wadepickett <10985336+wadepickett@users.noreply.github.com> Co-authored-by: Wade Pickett <wpickett@microsoft.com> Co-authored-by: Daniel Roth <daroth@microsoft.com>
1 parent acba8a5 commit 801b9b3

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

aspnetcore/release-notes/aspnetcore-11.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: wadepickett
55
description: Learn about the new features in ASP.NET Core in .NET 11.
66
ms.author: wpickett
77
ms.custom: mvc
8-
ms.date: 05/13/2026
8+
ms.date: 05/14/2026
99
uid: aspnetcore-11
1010
---
1111
# What's new in ASP.NET Core in .NET 11
@@ -80,6 +80,8 @@ This section describes miscellaneous new features in .NET 11.
8080

8181
[!INCLUDE[](~/release-notes/aspnetcore-11/includes/runtime-async-shared-framework-preview4.md)]
8282

83+
[!INCLUDE[](~/release-notes/aspnetcore-11/includes/rate-limiting-retry-after-preview-4.md)]
84+
8385
## Breaking changes
8486

8587
Use the articles in [Breaking changes in .NET](/dotnet/core/compatibility/breaking-changes) to find breaking changes that might apply when upgrading an app to a newer version of .NET.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
### Rate-limiting middleware returns accurate `Retry-After` headers
2+
3+
The <xref:System.Threading.RateLimiting.FixedWindowRateLimiter> now reports a <xref:System.Threading.RateLimiting.MetadataName.RetryAfter> metadata value that accurately reflects the next window boundary. Apps that propagate this metadata to the `Retry-After` response header in their <xref:Microsoft.AspNetCore.RateLimiting.RateLimiterOptions.OnRejected> callback now produce correct retry intervals automatically, with no code changes required.
4+
5+
Additional fixes in `System.Threading.RateLimiting` resolve an issue where <xref:System.Threading.RateLimiting.TokenBucketRateLimiter> mishandled partial token refills during zero-permit acquisition, and improve the chained rate limiter returned by <xref:System.Threading.RateLimiting.RateLimiter.CreateChained*> to correctly forward idle-duration and replenishment behavior from its inner limiters.
6+
7+
For an overview of the rate limiting middleware, see [Rate limiting middleware in ASP.NET Core](/aspnet/core/performance/rate-limit).
8+
9+
Thank you [@asbjornvad](https://github.com/asbjornvad) and [@apoorvdarshan](https://github.com/apoorvdarshan) for these contributions!

0 commit comments

Comments
 (0)