Adrian, On Mon, Mar 10, 2008 at 5:44 AM, Adrian Chadd <adrian@xxxxxxxxxxxxxxx> wrote: > Hm, it doens't do this already? nope, at least not in a way I would expect it to. > Well, it certainly wouldn't be difficult to. File a bugzilla report; > see if it tickles the fancy of anyone. Did it. Will see how it goes. Thanks! // Aurimas > On Sat, Mar 08, 2008, Aurimas Mikalauskas wrote: > > Hello, > > > > For the setup I'm about to discuss, I used to use varnish, but due to > > stability issues decided to use squid instead. It's a rather usual > > reverse-proxy setup with squid 3.0. However, I do have one issue that > > could have been solved easily with varnish, but I can't find a good > > solution for squid. Thing is: > > > > Pages are cached. I want them to be cached, but.. there are some users > > that come with a Cookie NOCACHE. I want those users to get fresh > > pages, but at the same time, I want that other users would gather the > > cached pages as usually. I tried the following: > > > > acl nocache_cookie req_header Cookie NOCACHE > > cache deny nocache_cookie > > > > However, as described in > > http://www.squid-cache.org/Versions/v3/3.0/cfgman/cache.html - "use > > this to force certain objects to never be cached" and not only it does > > not cache then - but also updates it's cache lists that the object is > > not cached. So what I get is: > > > > #1 user comes w/o NOCACHE -- she gets a CACHE_MISS, page from > > originserver, and gets it cached > > #2 user comes w/o NOCACHE -- she gets a CACHE_HIT i.e. the cached page > > #3 user comes w/ NOCACHE -- she gets a CACHE_MISS and fresh page > > directly from originserver (page does not get cached) > > #4 user comes w/o NOCACHE -- she gets a CACHE_MISS, page from > > originserver, and gets it cached > > > > and obviously this is not what I want - I'd rather have page kept in > > cache at step #3 (at the same time feeding the page directly from > > originserver to user #3). > > > > In varnish I could have achieved that with > > > > sub vcl_recv { > > if (req.http.Cookie ~ "NOCACHE") { > > pass; > > } > > } > > > > > > Appreciate your thoughts! > > > > // Aurimas > > -- > - Xenion - http://www.xenion.com.au/ - VPS Hosting - Commercial Squid Support - > - $25/pm entry-level VPSes w/ capped bandwidth charges available in WA - >