Methods

Class Index [+]

Quicksearch

Merb::MemorySession

Sessions stored in memory.

Set it up by adding the following to your init file:

 Merb::Config.use do |c|
   c[:session_store]      = :memory
   c[:memory_session_ttl] = 3600 # in seconds, one hour
 end

Sessions will remain in memory until the server is stopped or the time as set in :memory_session_ttl expires. Expired sessions are cleaned up in the background by a separate thread. Every time reaper cleans up expired sessions, garbage collection is scheduled start.

Memory session is accessed in a thread safe manner.

Public Class Methods

store() click to toggle source

Lazy load/setup of MemorySessionStore. :api: private

    # File lib/merb-core/dispatch/session/memory.rb, line 31
31:     def self.store
32:       @_store ||= MemorySessionStore.new(Merb::Config[:memory_session_ttl])
33:     end

Public Instance Methods

store() click to toggle source

Bypass normal implicit class attribute reader - see below. :api: private

    # File lib/merb-core/dispatch/session/memory.rb, line 25
25:     def store
26:       self.class.store
27:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.