Skip to content
Browse files

Update session config notes

  • Loading branch information...
1 parent 02b3d5b commit f15527734aed189209b57d20b848d94282561de9 @mperham mperham committed
Showing with 3 additions and 6 deletions.
  1. +3 −6
@@ -81,14 +81,11 @@ Here's a more comprehensive example that sets a reasonable default for maximum c
config.cache_store = :dalli_store, '', '',
{ :namespace => NAME_OF_RAILS_APP, :expires_in =>, :compress => true }
-To use Dalli for Rails session storage, in `config/initializers/session_store.rb`:
+To use Dalli for Rails session storage that times out after 20 minutes, in `config/initializers/session_store.rb`:
- require 'action_dispatch/middleware/session/dalli_store'
- Rails.application.config.session_store :dalli_store, :memcache_server => ['host1', 'host2'], :namespace => 'sessions', :key => '_foundation_session', :expire_after => 30.minutes
+ Rails.application.config.session_store ActionDispatch::Session::CacheStore, :expire_after => 20.minutes
-Both cache and session stores support `:raise_errors` parameter, which propagates exceptions (e.g. if all memcache servers are down) instead of silently hiding errors.
-Dalli does not support Rails 2.x any longer.
+Dalli does not support Rails 2.x.

0 comments on commit f155277

Please sign in to comment.
Something went wrong with that request. Please try again.