On Mon, Jun 22, 2009 at 7:26 PM, Henrik Nordstrom<[email protected]> wrote: > mån 2009-06-22 klockan 12:03 +0700 skrev johan firdianto: >> I already add refresh pattern >> refresh_pattern -i xxxxx 999888 100% 999999 ignore-no-cache >> ignore-reload override-expire override-lastmod reload-into-ims >> this could help to force cache the object ? > > Squid never caches POST responses. This due to some ambiguity on what > caching of POST responses really means, and the fact that most POST > responses are very dependent on the POST:ed data.
yes, absolutely. In a file sharing sites, in order to download a file they use POST method. after i analyze their uri of POST is unique enough. So whatever next request post method, as long as uri of post method is same and different data that POST:ed will return the same file/object. So my aim is to cache the response of POST, after that I pull the object out of swap cache (using curl or wget), and put in the other directory. And next time, I use url rewrite to trap the post method in case the same request comes again. I know, this is will be odd when applied to all sites. many mp3 song that downloaded many times from a file sharing site, and can't be cached because using post method. this site has ranks 25 in traffic (according alexa.com). Could u give me idea, what should i do ? Regards, Johan > In HTTP terms caching of a POST response actually means that it will be > returned as a cache hit on a later GET for the same URL. But this is a > bit counter-intuitive to most people and I guess not what you are > looking for.. > > Regards > Henrik > >
