Active
Project:
Cache Actions
Version:
7.x-2.0-alpha5
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
9 Apr 2013 at 19:46 UTC
Updated:
13 Jan 2016 at 22:58 UTC
Jump to comment: Most recent
I see that the 6.x version includes Varnish rules actions, but I can't find them anywhere for 7.2. The documentation refers to them; where can I find them to add them to my rules? thanks!
Comments
Comment #1
mariano.barcia commentedwondering the same here
Comment #2
bibo commentedI think you are looking for the cache_page bin? It can be used when varnish-module is setup and used as cache backend, like this in settings.php:
In rules you then clear a cache-bin of type page_cache. In the box you can specify the url, or url-matching regex-pattern (without hostname).
Comment #3
bibo commentedHope my answer cleared things up.
Btw: the expire module 7.2-series also has rules integration, and can be used to flush page caches in a similar way.
Comment #4
bibo commentedSettings this as fixed.
Comment #6
vinmassaro commented@bibo: I dug through the code and the 7.x-2.x-dev version only lets you choose to flush the cache_page bin, but does not offer a 'Clear cached paths in Varnish' option the way the 6.x-2.x version of the module does. That version allows for you to specify paths or regex to clear. The 7.x-2.x version does not have this functionality, and just lets you flush the cache_page bin which flushes all cached pages from Varnish.
Comment #7
vinmassaro commentedI'm reopening this because my solution doesn't seem to work in #6. I also can't get this to work when choosing the 'Clear a specific cache cid' option and passing in a few paths. I basically have a rule that checks if a certain content type has been updated, and I'm trying to flush the home page and the Latest News page from Varnish. Right now I had to resort to doing this from a 'Execute custom PHP code' action:
Can someone confirm they have this working to clear paths in Varnish using what is provided with Cache Actions?
Comment #8
robinmofo commentedCache actions does not integrate with Varnish, yeah it can clear the cache_page table but that's not Varnish.
You'll be better off installing the expire module which will also allow better control over the headers sent to Varnish as well as having the needed hooks firing to purge from Varnish when you do things like update content.
I've always installed expire for Varnish and cache_actions for Drupal caches.