Rate limiting for .NET

published on 2022/07/15

Rate limiting is the concept of limiting how much a resource can be accessed. For example, you know that a database your application accesses can handle 1000 requests per minute safely, but are not confident that it can handle much more than that. You can put a rate limiter in your application that allows 1000 requests every minute and rejects any more requests before they can access the database. Thus, rate limiting your database and allowing your application to handle a safe number of requests without potentially having bad failures from your database.

Microsoft DevBlogs

It's great that finally .NET has a standard APIs for rate limiting. It is such a useful facility when you are providing public APIs.