envoyproxy / envoyproxy/envoy

Envoy to pass hits_addend to RateLimitService

Open
#12,969 27 comments 3 reactions 0 assignees View on GitHub
area/ratelimit help wanted
Dominant language
C++
Stars
28.9k
Forks
5.6k
Avg merge
1d 22h
Merged PRs (30d)
430

Description

## Description
The [RLS v3 api](https://www.envoyproxy.io/docs/envoy/latest/api-v3/service/ratelimit/v3/rls.proto) describes the RateLimitService as able to injest a hits_addend field to determine number of tokens to use for the rate limiting request.
Envoy should provide a method for extracting a value from a request header (or some other method) to populate this method on a _per request_ basis. If hits_addend is only static, then it is effectively the same as modifying the ratelimit.

### Use case
In the [HTTP Rate Limit Filter](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/rate_limit_filter#config-http-filters-rate-limit) allow for a configuration of a request header containing an integer hits_addend value to send with the rate limit request, allowing for greater configurability of rate limiting capabilities.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.