caching of request with cookies

Harm Verhagen harm.verhagen at gmail.com
Tue Sep 28 10:28:03 CEST 2010


Hi

On Mon, Sep 27, 2010 at 1:39 PM, Tollef Fog Heen <
tfheen at varnish-software.com> wrote:

> ]] Harm Verhagen
>
> Hi,
>
> | This seems a bit too conservative to me.
> | According to the http specs the mere existence of a cookie should not
> | influence cachebility.  In the content of the response depends on the
> | cookie, the server should tell in the response that the contents are not
> | cacheble.
> | The Vary: Cookie header  exists for that reason, no ?
>
> In an ideal world, you are right.  Unfortunately, the world is not ideal
> and it's far between systems in the wild that does Vary: cookie.  If
> your system does, great, just change the VCL. :-)
>

This 'ideal' system is django (out of the box).
I do think a reverse proxy project should also support systems that are
trying to behave ideally.
However most (all?)  of the VCL examples found on the varnish site, and even
VCL examples on forums, are about how to trick varnish into caching when the
system 'misbehaves'.
This is good & usefull, but somehow  the systems that try to follow the http
spec are overseen in the docs.

So i'm actually a) looking for a VCL example for systems that try to behave
ideally.  and b) a request to promote this in the documentation.

This not just a problem with varnish, but other reversy proxies projects
seems to have the same issue. Most configuration examples  & documentation
is geared towards systems that misbehave.


>
> | What are the thoughts on this list about moving the default varnish
> | configuration closer to the http specification, regarding caching of
> request
> | where the client sends a cookie (and probably leading to problems on
> | websites that do _not_ use http headers correctly)
>
> I think changing the current behaviour would be a terribly bad idea.
> We've seen people mess this up before, causing significant financial
> losses.
>
Fair enough.

Regards,
Harm
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-dev/attachments/20100928/d652a259/attachment-0003.html>


More information about the varnish-dev mailing list