Conditional Requests (revisited)

Poul-Henning Kamp phk at phk.freebsd.dk
Mon May 5 21:23:30 CEST 2008


In message <DFE1F40E7B5641F8862AD7308F6DD8E6 at T60>, "Brian Smith" writes:

>(1) I have a back-end that is very fast for validating ETags and generating 
>304 Not Modified, but very slow when it has to return a new response body. 
>My understanding is that Varnish will never send conditional requests to the 
>backend, and it cannot use a 304 response to update the freshness 
>information for an already-cached response. Is that correct? 

Correct.

>If so, is there a way to do that in VCL?

Not that I can think off.

>Would you be willing to accept patches to implement that behavior in the core?

Provided they are well thought out: yes, then all patches are welcome.

Think hard about how to enable this sensibly in VCL.

>(2) I would like to cache entities with max-age=0 by using the logic from 
>(1) above to always revalidate the cached representation with the back-end. 

You can always override the TTL calculation in VCL, but doing the
revalidation with the backend is not possible until it gets implemented.

>If this is not possible, would you accept a patch to make this possible?

As above.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



More information about the varnish-misc mailing list