tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 25133] - Cannot add responses headers in filter after doFilter
Date Tue, 02 Dec 2003 12:11:26 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25133>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25133

Cannot add responses headers in filter after doFilter





------- Additional Comments From kevinj@develop.com  2003-12-02 12:11 -------
Thanks Tim

> To get around this - you need to wrap the ServletOutputStream and buffer it to
> prevent it from being committed. There are many articles on the net about
> filters and wrappers.

d'oh! and I've written a few of them so I should have realised this :)

However, the response will have been committed after a 304  yet the headers are
then set, so I would still regard this as a bug. I would think thet after
returning from a doFilter, logically speaking, either the response is committed
or it isn't. What was confusing to me is that I see the headers in one case but
not in the other. I realise that a 304 contains no data, but logically it is a
committed response

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


Mime
View raw message