SumoLogic-Labs / sumocli

Sumocli is a CLI application written in Go that allows you to manage your Sumo Logic tenancy from the command line.
Apache License 2.0
6 stars 4 forks source link

Consider rate limiting #29

Open jburger opened 3 years ago

jburger commented 3 years ago

Looks like many of the SL API have rate limiting. https://help.sumologic.com/APIs/Collector-Management-API/Collector-API-Methods-and-Examples#response-fields

While it is early in the project, it might be worth considering baking in support for throttling requests sent by the CLI to assist in rate limit avoidance.

wizedkyle commented 3 years ago

I think that is a good idea looks a simple as looking for a 429 status code then essentially backing off.

If a rate is exceeded, a rate limit exceeded 429 status code is returned.