You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can I keep this? Can the determination be a global ratelimit as explained in the official documentation? Anonymous users are 10/s and authenticated users are 100/s.
Hey Clara, thanks for the interest on this. Well, I believe the goal here is to add a rate limit independent the value itself, in another words, in a real world, we want to avoid a DDoS attack and by doing any rate limit we'll add this mechanism to the template where in a real project, they can adjust the value.
In this way, I would do:
Make sure the rate limit is per client (I believe it will use the client IP)
Add a 10/s regardless the user is logged or not
A plus (but not scope for this task) would be adding some load testing, perhaps using the https://k6.io/, where without this mechanism the load testing would make the app crash. But by having a rate limit, it will reject request after a certain number and the app should keep alive.
Thanks.
p.s: let me know if need any kind of help
p.s.s: some tips (just in case)
I prefer to create a project using the latest djavue3 version, add git and make commit. Then make the changes on the working project, then using git diff I can see the changes and apply them on djavue3 branch. (rather than try to change the repo directly)
After changing the djavue template, to test your local changes, you can run the cookiecutter agains your local folder (instead the github repo): cookiecutter /home/roger/coding/djavue3
After making the push, we can test the template using our branch cookiecutter https://github.com/muyser/djavue3 -c mybranch_name
In ideal world, the rate limit should be added both for the django only mode and for the django ninja, however, it is totally fine do it just for the former one.
Aproveitar a facilidade do django ninja e adicionar Rate Limit:
https://django-ninja.dev/guides/throttling/
The text was updated successfully, but these errors were encountered: