Len Popp wrote:
The issue was originally raised by Joe Mun on the Tomcat Users list:
http://marc.info/?l=tomcat-user&m=117934336727314&w=2

I looked at the behaviour in Tomcat 5.5.23 and it looks like Tomcat is
not handling ETag headers as required by the HTTP spec, when it
returns a 304 ("not modified") response for a file. For a 304
response, the spec says:
"The response MUST include the following header fields:
...
- ETag and/or Content-Location, if the header would have been sent
       in a 200 response to the same request"
(RFC 2616 10.3.5)
I take that to mean that if the server includes ETag headers when it
sends files, it must also include them when it sends 304's for those
same files. However Tomcat 5.5 doesn't do this. When a static file is
requested, Tomcat includes the ETag when it sends the file (with 200
status code) but omits it if it sends a status 304 response.

I did a simple test to verify this, requesting the same file twice to
get first a 200 and then a 304 response from Tomcat. The headers, as
reported by Firefox's Live HTTP Headers plugin, can be seen here:
http://marc.info/?l=tomcat-user&m=117950251422474&w=2

Am I correct that this is incorrect behaviour?

Yes, I think that's correct. It's bug.

Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to