The settings form from the domain_conf module only supports two caching modes, normal and disabled. If using Pressflow and a reverse proxy such as Varnish the caching mode should be external.
If the user submits the domain_conf settings form for a domain the cache variable is reset to normal and it is not possible to go back to external mode. This prevents Varnish from caching requests.
The attached patch adds the external caching mode and page_cache_max_lifetime settings to the domain_conf settings form when using Pressflow.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | 1101853-3-domain_conf_cache_external.patch | 1.26 KB | Yoshi |
| domain_conf_cache_external-d6.patch | 1.71 KB | kasperg |
Comments
Comment #1
agentrickardNode Access modules do not support external caching, AFAIK.
Please prove otherwise.
Comment #2
mstrelan commentedI am fairly new to this Varnish/Pressflow thing, but from my understanding the caching only works for anonymous users. As soon as the SESS cookie is created you no longer have Varnish cache. Drupal 6 by default creates the session cookie straight away, that is why you need PressFlow or Drupal 7 which will lazy-load the session when it is needed. Since all anonymous users are equal until a session variable appears you should be able to safely cache these page visits from anonymous users. Therefore +1 on the patch from me, but would probably be useful getting an expert (eg someone from FourKitchens) to review it.
Comment #3
agentrickardI think that is correct as well.
Comment #4
Yoshi commentedUpdated to work with drush make (strip = 1).
:)
Comment #5
agentrickard@Yoshi
I will assume that means the patch works for you?
Please mark such issues RTBC or they never get committed.
Comment #6
agentrickardCommitted to 6.x. There is no Pressflow for 7 yet, so I don't know how this will affect the patch.
Re-open if / when needed for 7.