- Local rate limiting (
localRateLimit) — token-bucket rate limiting applied in-process. State is not shared across instances. - Remote rate limiting (
remoteRateLimit) — rate limiting delegated to an external Envoy Rate Limit Service compatible gRPC server. State is shared across all gateway instances.
binds[].listeners[].routes[].policies.
Local rate limiting
Local rate limiting uses a token-bucket algorithm. Each route maintains its own bucket in memory.A list of token-bucket rate limit configurations applied to the route. State is kept local to the process.
Local rate limiting example
Remote rate limiting
Remote rate limiting delegates rate limit decisions to an external gRPC service compatible with the Envoy Rate Limit Service API. The gateway sends descriptor entries to the service, which returns allow/deny decisions.Rate limit incoming requests using an external rate limit service.
Remote rate limiting example
- Gateway config
- Rate limit service config
The remote rate limit service must implement the Envoy Rate Limit Service gRPC API. The
host value must include the port (e.g. 127.0.0.1:8081).