-
Notifications
You must be signed in to change notification settings - Fork 336
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
Non expiring Redis keys in Rails 5.2 #349
Comments
Hi @morgoth, thank you very much for reporting this issue. I can reproduce the problem on my side also. |
|
Thank you |
For whoever is interested, Rails has changed this in |
It was released in activesupport |
When using Rails 5.2 and built in Redis cache store https://github.com/rails/rails/blob/master/activesupport/lib/active_support/cache/redis_cache_store.rb
keys sets in Redis are not expiring.
This most likely is becuase:
Rails.cache
Rails.cache
responds toincrement
, but it ignoresexpires_in
option, thus it results in non expiring keysIt's a serious issue as the Redis db grows quickly on the big traffic.
Workaround found so far:
Rack::Attack.cache.store = Redis.current
, but only with #348It may also be resolved by closed #340 - but I didn't check it
The text was updated successfully, but these errors were encountered: