title: Using memcache in a Rails 3 app
body: <p>Do you have to add code to your Rails app to use memcache?  I've added <code>config.cache_store = :dalli_store</code> to my production environment and <code>Rails.cache.write('color', 'red')</code> works.</p>
  
  <p>I haven't made any modifications to my models, views, or controllers.  When I create and save an object, for example</p>
  
  <pre><code>user = User.new
  user.name = 'John Doe'
  user.email = 'john@doe.com'
  user.save
  </code></pre>
  
  <p>it is going straight to the database and not going to memcache.  I was hoping activerecord would use memcache automatically if configured for it.  Is that not the case?  Any good articles on rewriting your models to use Rails.cache (or should this be something done in the controller)?</p>