Replies: 1 comment 2 replies
-
I do not think that such requirements are related to reate-limiting domain. It looks like regular businness restrictions that can be covered by triggers and similar database provided integrity checks. You should use Bucket4j if and only if your usecase particulary covered by Token bucket, otherwise you should choose another way. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello. I decided to keep max limit buckets for every user in mysql database. For example every user is permitted to create only 10 channels in my chat app from the beginning of registration till death!! if it is his first request for creating channel, a bucket with 10 token is created and a token is consumed. and if it is not the first time, bucket table is checked and a token is consumed from the remaining tokens. there could be five or six or more maxLimits for each user(for examle: channel creaqtion max limit, group creation max limit, ...). I want you to suggest me the best way! my users can exceed 10 million and if each one of them user every request with max limit it can reach a 50 or 60 million row table. in your opinion which one is better? insert all buckets for all the max limits in a table or a table for each max limit? and if I you select multi table, I should insert tables settings to sqlproxy configuration at the beginning of app runtime?
I appreciate your help.
@vladimir-bukhtoyarov
Beta Was this translation helpful? Give feedback.
All reactions