README in interlock-1.3 vs README in interlock-1.4
- old
+ new
@@ -13,14 +13,12 @@
== Requirements
* memcached (http://www.danga.com/memcached)
* memcache-client gem
-* Rails 1.2.6
+* Rails 2.1
-Note that Rails 2.0.2 is required for caching <tt>content_for</tt> or nesting <tt>view_cache</tt> blocks.
-
== Features
Interlock is an intelligent fragment cache for Rails.
It works by making your view fragments and associated controller blocks march along together. If a fragment is fresh, the controller behavior won't run. This eliminates duplicate effort from your request cycle. Your controller blocks run so infrequently that you can use regular ActiveRecord finders and not worry about object caching at all.
@@ -35,11 +33,11 @@
You also need either <tt>memcache-client</tt> or {memcached}[http://blog.evanweaver.com/files/doc/fauna/memcached]:
sudo gem install memcache-client
Then, install the plugin:
- script/plugin install -x svn://rubyforge.org/var/svn/fauna/interlock/trunk
+ script/plugin install git://github.com/fauna/interlock.git
Lastly, configure your Rails app for memcached by creating a <tt>config/memcached.yml</tt> file. The format is compatible with Cache_fu:
defaults:
namespace: myapp
@@ -47,16 +45,16 @@
client: memcache-client
development:
servers:
- 127.0.0.1:11211 # Default host and port
production:
- servers
- - 10.12.128.1
- - 10.12.128.2
+ servers:
+ - 10.12.128.1:11211
+ - 10.12.128.2:11211
Now you're ready to go.
-Note that if you have {memcached 0.7}[http://blog.evanweaver.com/files/doc/fauna/memcached], you can use <tt>client: memcached</tt> for better performance.
+Note that if you have the {memcached}[http://blog.evanweaver.com/files/doc/fauna/memcached] client, you can use <tt>client: memcached</tt> for better performance.
== Usage
Interlock provides two similar caching methods: <tt>behavior_cache</tt> for controllers and <tt>view_cache</tt> for views. They both accept an optional list or hash of model dependencies, and an optional <tt>:tag</tt> keypair. <tt>view_cache</tt> also accepts a <tt>:ttl</tt> keypair.