-
Notifications
You must be signed in to change notification settings - Fork 32
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
Simplify configuration with an actual cache store #21
base: master
Are you sure you want to change the base?
Conversation
@fcheung Did this actually enable you to configure elasticache with the running EC2/Beanstalk instance? How do I confirm that this is working? Thanks |
It does (sorry about not getting around to finishing it off. As far as confirming its working you could inspect Rails.cache in the console and also check that values are actually cached. |
Thanks.I will try and keep up posted. Raghu |
I tried this change in production.rb and deploying to elastic beanstalk I get the following error in the console [Instance: i-13ec4bdc] Command failed on instance. Return code: 1 Output: (TRUNCATED)...g/environment.rb:6:in Seems that dallI_elasticache_store is not loading, because of which deployment fails. I went to console elastic-beanstalk and installed the gem dalli-elasticache, still no difference. Anything I may be missing? Thanks |
It would also need to be in your Gemfile. We've been using this in production for some time now. |
It was there. Worked. Modified the config/initializers/session_store.rb for Rails >3.2.4 to put Rails.application.config.session_store ActionDispatch::Session::CacheStore, :expire_after => 30.minutes This did the trick. Thanks for your help. Raghu |
Would love to see this get merged. All you're waiting on are specs, @ktheory? |
Yup, and would be nice to update the README too. Feel free to make an alternative PR if you'd like to pick this up. |
This allows one to do
as suggested in #12