Is there a way to set the directory structure for the fragment cache? I know by default it is using Zlib.adler32 to generate the directory name for a key. Is there any way to configure this? I want to be able to clear the fragment cache externally from the app by a different process. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On Mon, Nov 29, 2010 at 12:51 PM, Robert R. <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> Is there a way to set the directory structure for the fragment cache?Yes, you can use the following: config.cache_store = :file_store, "/path/to/cache/directory"> I > know by default it is using Zlib.adler32 to generate the directory name > for a key. > > Is there any way to configure this? I want to be able to clear the > fragment cache externally from the app by a different process. > >It seems that :mem_cache_store may be what you''re looking for because it uses a seperate process to manage an application''s cache. However, it''s in memory instead of the disk. I would recommend reading the following for additional information: http://guides.rubyonrails.org/caching_with_rails.html Good luck, -Conrad> -- > Posted via http://www.ruby-forum.com/. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to > rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org<rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> > . > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Conrad Taylor wrote in post #964899:> On Mon, Nov 29, 2010 at 12:51 PM, Robert R. <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> > wrote: > >> Is there a way to set the directory structure for the fragment cache? > > > Yes, you can use the following: > > config.cache_store = :file_store, "/path/to/cache/directory" > > >> I >> know by default it is using Zlib.adler32 to generate the directory name >> for a key. >> >> Is there any way to configure this? I want to be able to clear the >> fragment cache externally from the app by a different process. >> >> > It seems that :mem_cache_store may be what you''re looking for > because it uses a seperate process to manage an application''s > cache. However, it''s in memory instead of the disk. I would > recommend reading the following for additional information: > > http://guides.rubyonrails.org/caching_with_rails.html > > Good luck, > > -ConradWell, all that does for me is allow me to move the cache directory. It does not allow me to set the directory name structure. I want predictable names (views/domain/controller/action/key for example), not 0EF/2FF/(etc). I retested it just to make sure. I set it to be "tmp/cache2" Here is my cache2 directory cd tmp/cache2/ Robert-Rouses-MacBook-Pro:cache2 robertrouse$ ls 152 154 1BE 210 4BA -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
I have juste above a a message that is telling me that this post is 6 months old… but I still sort of resolve this problem with the explanation here ›› http://scottiestech.info/2011/07/23/fixing-the-rails-3-fragment-cache-path -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.