public
Description: ActiveSupport::Cache wrapper for libmemcached
Homepage:
Clone URL: git://github.com/37signals/libmemcached_store.git
name age message
file .gitignore Thu Jun 12 10:05:41 -0700 2008 Initial commit [Jeff Hardy]
file MIT-LICENSE Thu Jun 12 10:07:54 -0700 2008 Import libmemcached_store [Jeff Hardy]
file README Mon Aug 18 12:48:01 -0700 2008 Update README [Jeffrey Hardy]
file Rakefile Thu Jun 12 10:07:54 -0700 2008 Import libmemcached_store [Jeff Hardy]
file init.rb Tue Aug 12 08:04:32 -0700 2008 Remove dead init code [Jeffrey Hardy]
directory lib/ Sat Aug 23 17:26:48 -0700 2008 Don't log an error on Memcached::NotFound since... [Jeffrey Hardy]
directory test/ Sat Aug 23 16:42:08 -0700 2008 Update tests to reflect that the 'namespace' op... [Jeffrey Hardy]
README
= LibmemcachedStore

An ActiveSupport cache store that uses the C-based libmemcached client through
Evan Weaver's Ruby/SWIG wrapper, memcached. libmemcached is fast, lightweight,
and supports consistent hashing, non-blocking IO, and graceful server failover.

== Prerequisites

You'll need both the libmemcached client and the memcached gem:

* http://tangent.org/552/libmemcached.html
* http://blog.evanweaver.com/files/doc/fauna/memcached

Make sure you install libmemcached first, before you try installing the gem. If
you're using OS X, the easiest way to install libmemcached is through MacPorts:

  sudo port install libmemcached

For other platforms, download and extract the libmemcached tarball and install
manually:

  ./configure
  make && sudo make install

Once libmemcached is installed, install the memcached gem:

  gem install memcached --no-rdoc --no-ri

== Usage

This is a drop-in replacement for the memcache store that ships with Rails. To
enable, set the <tt>config.cache_store</tt> option to <tt>:libmemcached_store</tt>
in the config for your environment

  config.cache_store = :libmemcached_store

If no servers are specified, localhost is assumed. You can specify a list of
server addresses, either as hostnames or IP addresses, with or without a port
designation. If no port is given, 11211 is assumed:

  config.cache_store = :libmemcached_store, %w(cache-01 cache-02 127.0.0.1:11212)

== Props

Thanks to Brian Aker (http://tangent.org) for creating libmemcached, and Evan
Weaver (http://blog.evanweaver.com) for the Ruby wrapper.