Class Riak::SessionStore
In: lib/riak/session_store.rb
Parent: Rack::Session::Abstract::ID

Lets you store web application session data in Riak. Useful for those cases where you need more than the 4K that cookies provide.

Usage (Rack builder):

  use Riak::SessionStore

Usage (Rails):

  config.middleware.use Riak::SessionStore

Usage (Rails 2.3), requires you to swap out the default store:

  config.middleware.swap ActionController::Session::CookieStore, Riak::SessionStore

For configuration options, see initialize.

Methods

generate_sid   new  

Constants

DEFAULT_OPTIONS = Rack::Session::Abstract::ID::DEFAULT_OPTIONS.merge \ :host => "127.0.0.1", :http_port => 8098, :bucket => "_sessions", :r => 1, :w => 1, :dw => 0, :rw => 1, :n_val => 2, :last_write_wins => false, :content_type => "application/x-ruby-marshal"

Attributes

bucket  [R] 

Public Class methods

Creates a new Riak::SessionStore middleware @param app the Rack application @param [Hash] options configuration options @see Rack::Session::Abstract::ID#initialize

Public Instance methods

[Validate]