Deploy rate limiting for the rest gateway on the staging cluster for manual testing.
Steps:
- Create a list of URLs to test against (using bash/curl, Siege, or Locust)
- Enforce limits on all routes, but only if the client specifies the x-wmf-user-class header (or equivalent). Test that rate limit is enforced.
- Set global shadow mode, test that rate limit is no longer enforced but logs/stats provide useful information
- Enable rate limiting (in shadow mode) on routes that opt into rate limiting, regardless of the x-wmf-user-class being given (and ensure such headers are ignored if thy come from the client).
Stretch:
- Test selectiv shadow mode [needs Envoy 1.33]
For the purpose of this test, the rate limits should be configured very log, e.g. 3 per minute for anon and 10 per minute for users.