Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wolny/rack-session-redis
Provides simple cookie based session management, with the session data stored in Redis
https://github.com/wolny/rack-session-redis
rack redis ruby sessionservice
Last synced: about 1 month ago
JSON representation
Provides simple cookie based session management, with the session data stored in Redis
- Host: GitHub
- URL: https://github.com/wolny/rack-session-redis
- Owner: wolny
- License: mit
- Created: 2014-07-03T15:43:00.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-07-10T10:52:45.000Z (over 10 years ago)
- Last Synced: 2023-03-12T00:37:17.829Z (almost 2 years ago)
- Topics: rack, redis, ruby, sessionservice
- Language: Ruby
- Size: 141 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Rack::Session::Redis
*Rack::Session::Redis::SessionService* provides simple cookie based session management.
Session data is stored in Redis and the corresponding session key is maintained in the cookie.
You may treat SessionService as you would Rack::Session::Pool.You can use all options supported by *Rack::Session::Abstract::ID*.
## Installation
Add this line to your application's Gemfile:
gem 'rack-session-redis'
And then execute:
$ bundle
Or install it yourself as:
$ gem install rack-session-redis
## Usage
```
use Rack::Session::Redis::SessionService,
key: 'my_session_key',
domain: 'example.com',
path: '/',
expire_after: 3600,
redis_options: {host: 'redis-master.example.com', port: 6379, db: 13},
key_prefix: 'my:session:'
```