Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add configurable Redis key prefixes #316

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

jacobmstein
Copy link

Redis keys are conventionally namespaced using colons to avoid naming collisions and improve readability. Additionally, bare keys often make it difficult to view database contents from GUI clients, many of which group and filter keys by namespace.

For those reasons, this pull request introduces a RedisRateLimitOptions class with a KeyPrefix property.

@timonmasberg
Copy link

timonmasberg commented Mar 29, 2022

Actually, wouldn't it be enough to just remove the _ when we call the policy store, then we could use ClientPolicyPrefix for the counter key as well without introducing another option?

@jacobmstein
Copy link
Author

Actually, wouldn't it be enough to just remove the _ when we call the policy store

I suppose, however I find it unreasonable to alter its current behavior as a feature. In that case, a delimiter option (default _) needs to be added, which I'd be happy to do.

@ShawnWang6
Copy link

Why not merge this MR? I'm waiting for this feature.

@baramustafa
Copy link

Will this ever get merged in? Would be very handy if it could.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants