We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
How can I use redis-session-store with hiredis? Are there any examples that I can use to understand?
redis-session-store
hiredis
The text was updated successfully, but these errors were encountered:
Assuming that you have the hiredis gem in your Gemfile, just specify it as the driver in your redis options hash.
Gemfile
driver
redis
I pulled this straight from one of my working applications:
config.session_store :redis_session_store, { serializer: :json, on_redis_down: ->(*a) { logger.error("Redis down! #{a.inspect}") }, redis: { driver: :hiredis, expire_after: 2.weeks, key_prefix: "myapp:session:", url: ENV.fetch("REDIS_URL") { "redis://localhost:6379/0" } } }
Sorry if you died before getting this sorted out.
Sorry, something went wrong.
@leastbad I get ArgumentError: Unknown driver :hiredis, expected one of: '[:ruby]', is there something else other than adding hiredis gem?
ArgumentError: Unknown driver :hiredis, expected one of: '[:ruby]'
Ok, I figured it out, adding this to your Gemfile fixes above issue
gem 'hiredis-client'
No branches or pull requests
How can I use
redis-session-store
withhiredis
? Are there any examples that I can use to understand?The text was updated successfully, but these errors were encountered: