Tuesday, January 27, 2009

:rails => 'Clearing the Memcached Cache'

#drop in: /lib/tasks/cache.rake

namespace :cache do??desc 'Clear memcache cache'??task :clear => :environment do?? ActionController::Base.cache_store.clear??endend

#call:

rake cache:clear

Obviously, this is only useful if you’re using Memcached with your Rails site.


Via Strictly Untyped

No comments:

Post a Comment