tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shapira, Yoav" <Yoav.Shap...@mpi.com>
Subject RE: Logging filter (was RE: [next] What's next ?)
Date Thu, 02 Oct 2003 16:29:30 GMT

Howdy,

>--- "Shapira, Yoav" <Yoav.Shapira@mpi.com> wrote:
>> 1. Convert AccessLogValve to be a servlet
>> specification 2.3 filter, i.e.
>
>That sounds wonderful and useful, but there are a few
>problems here.  Filters don't have access to all the
>information that is needed to make a log entry the way
>the AccessLogValve does it.  Content length, response
>code and content type variables may not be known when
>the filter is processing, and (last time I checked)
>there is no byte[] Response.getContentType() method.
>There is setContentType() but no getContentType().

That's unfortunate ;(

getContentType() is there, actually, in ServletResponse.  But not
getContentLength() nor getStatusCode().  I was planning the
AccessLogFilter just support the Common and Combined access log files
patterns, and I imagined all the required fields for those patterns are
part of standard interfaces.

In fact, why aren't there methods like getHeader(String name) and
getContentLength() in the ServletResponse interface?  Can someone
familiar with the Servlet Specification comment on this?

Yoav Shapira



This e-mail, including any attachments, is a confidential business communication, and may
contain information that is confidential, proprietary and/or privileged.  This e-mail is intended
only for the individual(s) to whom it is addressed, and may not be saved, copied, printed,
disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately
delete this e-mail from your computer system and notify the sender.  Thank you.


---------------------------------------------------------------------
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