Hi, I came across a aHttpServletResponse.setHeader("Vary", "Accept-Encoding"), but I had never heard of a header "Vary". This is called in a code, that depending on the request header, will either a)send GZIP format b)ZIP format c)regular OutputStream. So, I suspect the "Vary" header gives servlet flexibility in this regard. Am I right? Can someone please confirm to it? Thanks.
I found the Vary header in RFC 2616 - the HTTP 1.1 definative document. Thats a long section so I am just quoting the first paragraph: "The Vary field value indicates the set of request-header fields that fully determines, while the response is fresh, whether a cache is permitted to use the response to reply to a subsequent request without revalidation. For uncacheable or stale responses, the Vary field value advises the user agent about the criteria that were used to select the representation. A Vary field value of �*� implies that a cache cannot determine from the request headers of a subsequent request whether this response is the appropriate representation. See section 13.6 for use of the Vary header field by caches." Download your very own copy from: http://www.w3.org/ So it looks like Vary controls caching somehow. Bill