Redis stores for Mobb

mobb-redis provides a Redis backed cache store for Mobb. See the main redis-store readme for general guidelines.

Installation

# Gemfile
gem 'mobb-redis'

Usage

require 'mobb'
require 'mobb-redis'

class MyApp < Mobb::Base
  register Mobb::Cache

  on 'hi' do
    settings.cache.fetch('greet') { 'Hello, World!' }
  end
end

Keep in mind that the above fetch will return "OK" on success, not the return of the block.

Running tests

gem install bundler
git clone https://github.com/kinoppyd/mobb-redis
cd mobb-redis
bundle install
bundle exec rake

If you are on Snow Leopard you have to run env ARCHFLAGS="-arch x86_64" bundle exec rake

Original 2009 - 2013 Luca Guidi - http://lucaguidi.com, released under the MIT license]

Modify kinoppyd