Rate limiting by percentage

Thangamani J thangamani.rect at gmail.com
Wed Jan 25 00:01:18 UTC 2017


Hi team,

I'm in process of implementing following use case, please help me with your
inputs.

let's say I have endpoint /rate-limit and it should
75% of time, it should return "SUCCESS" as text
25% of time, it should return "FAILED" as text

I did try limit_req_zone which goes by request per second and when exceeds
it responds with status code 503. But in this case i want an actual
response and the percentage of FAILED/SUCCESS to be configurable.

Any pointers for above use case would be helpful.

Thanks,
Thanga.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20170124/85a9a163/attachment.html>


More information about the nginx mailing list