Rate Limiting Algorithms
Compare fixed, sliding, token, and concurrency limiters.
Why Rate Limit?
Rate limiting caps how many requests a client can make in a window of time. It protects your API from abuse, runaway clients and accidental traffic spikes, and keeps capacity fair across users.
// e.g. allow 100 requests per minute per API keyBuilt-in Rate Limiting
Since .NET 7, ASP.NET Core ships a first-class rate limiting middleware in Microsoft.AspNetCore.RateLimiting with four built-in algorithms.
// Algorithms: Fixed Window, Sliding Window,
// Token Bucket, ConcurrencyAll lessons in this course
- Rate Limiting Algorithms
- Configuring Rate Limiting Middleware
- Output Caching Basics
- Cache Policies and Invalidation