You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Per connection rate limiting of HTTP requests #15637
Currently, the HTTP local rate limiter's token bucket is shared across all workers, thus causing the rate limits to be applied per Envoy instance/process. This could potentially result in bad actors quickly exhausting limits on a given instance before legitimate users have had a fair chance and in extreme cases even lead to starvation. We need a way to allocate token buckets for each connection thereby allowing us to rate limit requests per connection.
One possible option would be to allow specifying a scope on the local rate limit configuration, along the lines of:
Following this, depending on the configured scope, we could maybe add an instance of the LocalRateLimit::LocalRateLimiterImpl to the connection object that each HTTP request belongs to, if there isn't one already (perhaps via callbacks_->connection().streamInfo().filterState()->setData?)
Activity
snowp commentedon Mar 24, 2021
Seems like a reasonable enhancement, marking help wanted.
cc @rgs1
mattklein123 commentedon Mar 24, 2021
+1 I would like to see this happen. I think doing it via filter data sounds like a good plan.
Per connection local rate limiting (envoyproxy#15843)