carbonapi icon indicating copy to clipboard operation
carbonapi copied to clipboard

Per request rate limiting to carbonzipper

Open dgryski opened this issue 9 years ago • 4 comments

This will throttle bulk-style requests, but not adversely affect smaller API calls from proceding.

Requires a bit more thinking to figure out if this is a problem and if this is the best solution.

dgryski avatar Sep 25 '14 08:09 dgryski

This is nearly 2 years old - think we should still look at it?

nnuss avatar Aug 28 '16 09:08 nnuss

There were two issues I wanted to solve with this:

  1. limiting the number of HTTP connections that were made to the local zipper
  2. limiting the "burstiness" of a massive query, since that will overload the pipeline

The first issue will be solved with https://github.com/dgryski/carbonzipper/issues/16 (moving to grpc). The second one still needs to be considered.

dgryski avatar Aug 28 '16 09:08 dgryski

Re: 2) Graphite has moved to a single-phase /render request to the backing stores. If we also make that change as well as carbonserver support for multiple target: /render/?from=147...&to=147...&format=...&target=metric.a&target=metric.b&target=... ; do you think that could make substantial improvements to the connection "burstiness"? [Realize I'm suggesting something with its own performance implications.]

nnuss avatar Aug 28 '16 20:08 nnuss

Everything in the stack currently supports the single /render/ request. It works with globs, not multiple targets though.

dgryski avatar Aug 29 '16 08:08 dgryski