Description
Is your feature request related to a problem? Please describe.
There is two scenarios that I would like to see some amount of rate limiting happening:
-
Running the collector in a gateway deployment style (many stateless collectors running as deployment) can be accepting 3x traffic from Service A which can impact delivery of service B sending <1x scale.
-
Running the collector as a stand alone / sidecar deployment (Single node, potentially stateful with only a single service sending data).
If in either of the cases, the service sends an erroneous amount of traffic, it impact others trying to send through the same pipeline.
Describe the solution you'd like
A new extension made to the collector contrib that can potential rate limit of header fields or HTTP meta data information.
Ideally it should follow an exiting rate limiting convention that is widely adopted so that effort to update instrumentation is low touch.
Considering Option 1 case, the collector deployment will need to send data among each other to ensure that traffic is correctly rate limited (with some tolerance for eventually consistent).
Describe alternatives you've considered
Each collector could have an in memory counter that is of fix number B over T time.
Therefore the considered rate limit would be N nodes X B buckets / (2T) (assuming a drift of T between each node)
Which could work, but the drift might not be tolerable but adopters.
Additional context
There is some public projects that attempt to make generic solutions to this: