-kinetic
2009-May-04 18:04 UTC
How to reset Rails.cache servers? Rails.cache.reset is undefinied
I''m trying to get memcached working for my rails app that''s running under passenger. Apparently we need to check if passenger forked memcached, and if so we need to establish a new connection using a reset function. I''ve seen people install cache_fu and they''re able to call CACHE.reset. But for the built in memcache-client in Rails 2.x there''s no such Rails.cache.reset. What is the equivalent to this? Do I need to install cache_fu? everything works great on my dev machine with memcached running with mongrels.
pharrington
2009-May-05 16:36 UTC
Re: How to reset Rails.cache servers? Rails.cache.reset is undefinied
With Rails 2.3.2, use Rails.cache.clear I''m not sure about older versions, though. On May 4, 2:04 pm, -kinetic <kineti...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I''m trying to get memcached working for my rails app that''s running > under passenger. Apparently we need to check if passenger forked > memcached, and if so we need to establish a new connection using a > reset function. > > I''ve seen people install cache_fu and they''re able to call > CACHE.reset. But for the built in memcache-client in Rails 2.x > there''s no such Rails.cache.reset. > > What is the equivalent to this? Do I need to install cache_fu? > > everything works great on my dev machine with memcached running with > mongrels.
pharrington
2009-May-05 16:37 UTC
Re: How to reset Rails.cache servers? Rails.cache.reset is undefinied
Are you looking for Rails.cache.clear ? On May 4, 2:04 pm, -kinetic <kineti...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I''m trying to get memcached working for my rails app that''s running > under passenger. Apparently we need to check if passenger forked > memcached, and if so we need to establish a new connection using a > reset function. > > I''ve seen people install cache_fu and they''re able to call > CACHE.reset. But for the built in memcache-client in Rails 2.x > there''s no such Rails.cache.reset. > > What is the equivalent to this? Do I need to install cache_fu? > > everything works great on my dev machine with memcached running with > mongrels.