varnish && zope/plone: varnish does not find cachefu purges: returns 404 instead.

Rob Rogers robertbrogers at gmail.com
Tue Mar 16 04:28:45 CET 2010


The Issue: cachefu fails to purge cache on object changes.
This means user sees stale, incorrect content.
Product Versions: Plone-2.5.3, plone2.5.3, CacheFu-1.0.2, varnish-2.0.6

To reproduce:
* In browser1: login and go to any page
* In browser 2: view same page.
* In browser 1: edit page  (add some dots to title). save
* In browser 2: refresh page
THE BUG: browser 2 shows old version of page

Another way to reproduce this is to use portal_squid tool to purge  
article. Same problem occurs.

./bin/varnishlog shows the error:
"""
   16 RxURL        c http://dude.com.moneyXXX/archive/2010/february/the-thirteen-races-to-watch
    16 RxProtocol   c HTTP/1.0
    16 VCL_call     c recv
    16 VCL_acl      c MATCH purge localhost
    16 VCL_return   c lookup
    16 VCL_call     c hash
    16 VCL_return   c hash
    16 VCL_call     c miss
     0 Debug        - "VCL_error(404, Not in cache)"
"""

The odd thing is that normal requests from the browser produce a RxURL  
like:
 >>   13 RxURL        c /archive/2010/february/the-thirteen-races-to- 
watch

I find this odd, because the requests from the browser to varnish  
don't include the http host. I wonder if this version of cachefu  
doesn't work with varnish.

A couple notes:

* I tried messing with the varnish.vcl to normalize the http.host
/*      if (req.http.host ~ "(www.)?xxx.org") { */
/*        set req.http.host = "xxx.org"; */
/*      } else { */
/*        error 404 req.http.host; /\* "Unknown virtual host." *\/ */
/*      } */
but, it failed to produce desired results

* i started messing with it because of this post:
http://davidjb.com/blog/2009/01/plone-varnish-configuration-cache-hits-purge-fails
and this:
http://varnish-cache.org/wiki/VCLExampleNormalizingReq

Thanks for any help or guidance.

-Rob
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20100315/0163e845/attachment-0003.html>


More information about the varnish-misc mailing list