README.md in dalli-1.0.3 vs README.md in dalli-1.0.4
- old
+ new
@@ -42,11 +42,11 @@
require 'dalli'
dc = Dalli::Client.new('localhost:11211')
dc.set('abc', 123)
value = dc.get('abc')
-The test suite requires memcached 1.4.3+ with SASL enabled (brew install memcached --enable-sasl ; mv /usr/bin/memcache /usr/bin/memcached.old). Currently only supports the PLAIN mechanism.
+The test suite requires memcached 1.4.3+ with SASL enabled (brew install memcached --enable-sasl ; mv /usr/bin/memcached /usr/bin/memcached.old). Currently only supports the PLAIN mechanism.
Dalli has no runtime dependencies and never will. You can optionally install the 'kgio' gem to
give Dalli a 10-20% performance boost.
@@ -62,10 +62,10 @@
config.cache_store = :dalli_store
A more comprehensive example (note that we are setting a reasonable default for maximum cache entry lifetime (one day), enabling compression for large values, and namespacing all entries for this rails app. Remove the namespace if you have multiple apps which share cached values):
config.cache_store = :dalli_store, 'cache-1.example.com', 'cache-2.example.com',
- { :namespace => NAME_OF_RAILS_APP, :expires_in => 1.day, :compress => true, :compress_threshold => 64*1024 }
+ { :namespace => NAME_OF_RAILS_APP, :expires_in => 1.day, :compress => true }
To use Dalli for Rails session storage, in `config/initializers/session_store.rb`:
require 'action_dispatch/middleware/session/dalli_store'
Rails.application.config.session_store :dalli_store, :memcache_server => ['host1', 'host2'], :namespace => 'sessions', :key => '_foundation_session', :expire_after => 30.minutes