You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Chris Rossi <ro...@webslingerZ.com> on 2004/06/17 20:30:20 UTC
Tomcat 4.1.30 does not respect Date header
Hello. I am using Tomcat 4.1.30, with java 1.4.2 on a Readhat linux
server. I was going to submit a bug report, but I noticed the bug
tracker only goes through version 4.1.9. Is that bug tracker still
being used? Should I still submit bugs to it?
Anyway, I am implementing an HTTP Cache filter using the Java Servlet
Filter API. The HTTP spec (ftp:/ftp://ftp.isi.edu/in-notes/rfc2616.txt)
requires that a cached response set the "Date" response header to the
date/time that the response was generated. In my servlet filter I
accomplish this by calling:
response.setDateHeader( "Date", timestamp );
When I look at the actual HTTP generated response I'm finding that my
attempt to set the "Date" header is being ignored and the date of the
header always reflects the time "now". So when my filter returns a
cached response to the request, the Date header does not reflect the
time the cached response was created and my code ends up violating the
HTTP spec and breaks the manner in which the client should be
calculating the freshness of the requested resource.
This behavior is correct the majority of the time, however, there are
cases, like this one, where the programmer needs to explicitly set the
Date header. Do the developers agree with me that this is a bug, or am
I wrong somewhere in my reasoning? Please let me know.
Thanks,
Chris Rossi
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org