Class: ActionDispatch::Session::LibmemcachedStore
- Inherits:
-
AbstractStore
- Object
- AbstractStore
- ActionDispatch::Session::LibmemcachedStore
- Defined in:
- lib/action_dispatch/session/libmemcached_store.rb
Instance Method Summary collapse
-
#initialize(app, options = {}) ⇒ LibmemcachedStore
constructor
A new instance of LibmemcachedStore.
Constructor Details
#initialize(app, options = {}) ⇒ LibmemcachedStore
Returns a new instance of LibmemcachedStore.
8 9 10 11 12 13 14 15 |
# File 'lib/action_dispatch/session/libmemcached_store.rb', line 8 def initialize(app, = {}) [:expire_after] ||= [:expires] super = { default_ttl: .fetch(:expire_after, 0) } [:namespace] = [:namespace] || 'rack:session' @mutex = Mutex.new @pool = [:cache] || Memcached.new(@default_options[:memcache_server], ) end |