Open amirouche opened 3 years ago
The approach taken by flask-limiter
via limits
is wrong in this context. Spawning a POSIX thread for every unique client by IP is doomed to fail. One way to workaround it is to investigate REDIS backend in flask-limiter / limits OR rely on nginx [0] or apache rate limiting.
It is preferable to use apache or nginx rate limiting feature.
Under high load, flask-limiter inside limits will raise an exception because no more thread are available: