Using nginx rate limiting, using this rule as an example:
limit_req_zone $request_limiting_zone_key zone=request_limiting_search:20m rate=30r/m;
This will set 30 requests per minute. However what if I wanted to stack a second rule, so the logic is "30 requests per minute, or 1 request per second. Whichever comes first"
The reason for this is we still want a cap of 30/min but there are some weird attempts that we're seeing a spam of 10x requests in a 1-2 second period. This causes some issues when requests come through that fast. So we would like to limit users to 1 request a second, AND a cap of 30 per minute.
I read the doc reference but didn't see much around stacking different rate rules.
Is this possible? If so, what would be the syntax?