mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 10:20:58 -06:00
361992bb74
This commit moves the logic for crawler rate limits out of the application controller and into the request tracker middleware. The reason for this move is to apply rate limits to all crawler requests instead of just the requests that make it to the application controller. Some requests are served early from the middleware stack without reaching the Rails app for performance reasons (e.g. `AnonymousCache`) which results in crawlers getting 200 responses even though they've reached their limits and should be getting 429 responses. Internal topic: t/128810. |
||
---|---|---|
.. | ||
anonymous_cache_spec.rb | ||
discourse_public_exceptions_spec.rb | ||
enforce_hostname_spec.rb | ||
request_tracker_spec.rb |