tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier ...@ice-sa.com>
Subject Re: Trailer header and tomcat
Date Wed, 05 Aug 2009 23:09:52 GMT
Keyur,

I think what Filip was trying to tell you is this :

Servlet Specification 2.4, SRV 5.2, Headers :

"To be successfully transmitted back to the client, headers must be set 
before the response is committed. Headers set after the response is 
committed will be ignored by the servlet container."

(I believe you will find a similar paragraph in the 2.5 specification).

Tomcat is a HTTP web server, but it is also first a Java Servlet 
Container, and must follow the Java Servlet Specification.

What it means in clear is that as soon as 1 byte of the response has 
been sent out to the client (iow the response is committed), it is too 
late to set a header.
If you look at the Tomcat logfiles, you will probably find a warning 
message "Response already committed" whenever you try to add this header.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message