Re: ETags vs Variants, was: Revising RFC2616 - what's happening

Henrik Nordstrom schrieb:
> tor 2006-10-19 klockan 22:56 +0100 skrev Jamie Lokier:
>> While on the subject of Etag and variants, it's never been clear what
>> a Vary header that names a header not in the original request means.
> For me that never was a question. I immediately read Vary as the
> complete list of headers the server looked for while selecting which
> variant to send. But this may be just my reading of the RFC..

It doesn't help that "Vary" is described in two places, Section 13.6 and 

In 13.6 it says:

"When the cache receives a subsequent request whose Request-URI 
specifies one or more cache entries including a Vary header field, the 
cache MUST NOT use such a cache entry to construct a response to the new 
request unless all of the selecting request-headers present in the new 
request match the corresponding stored request-headers in the original 
request." (<>)

At least this part IMHO needs to be fixed to say how to treat the case 
where a header doesn't appear in the request.

> What isn't very clear to me was what change in Vary means on a URI.


>> But (a) is that use of Vary allowed
> I think so.
>> (b) is it consistently interpreted that way by caches, and
> Quite likely. I know at least Squid does it this way, and most others I
> have seen caching Vary.
> But many shared proxy caches still don't cache Vary responses at all.

Well, those aren't HTTP/1.1 compliant, so there's nothing we can do 
about those.

>> (c) it would be good for the improved RFC to clarify this.
> Probably. Many get Vary wrong. But the most common error I have seen is
> not sending Vary when it should have been sent and still expecting
> caches to do the right thing.. But I have not seen this dependent on the
> existence of the header in the request or not.

One of the reasons may be broken handling of Vary headers in user 
agents, mainly IE 
(<;en-us;824847>), but 
also Firefox (<>).

Best regards, Julian

Received on Friday, 20 October 2006 12:28:42 UTC