Its probably also failing for less than 8k since I am guess the view is a jsp and when the jsp finishes execution - the response will be committed. (Or somewhere in the request/response cycle - a forward() was done which also will eventually commit the response per the servlet spec)

If you are trying to log latency, your best bet is to use log4j or your favorite logging library and log everything to info(). Then when you need to see latency - you configure info level log message to appear.

-Tim

Anantha Padmanabha wrote:
Hi people,

You are correct. My header got ignored and was attempting to add after
'commit'.

I moved it to beginning of filter and tried updating towards the end, but
after 'commit', I wont be able to able to set the header value :(

I'm using struts2 application. I want to add some latencies [say mysql, our
components and tomcat itself] to header, so that I can print this in Apache
logs. Then looking at single apache log file, I would then be able to see
what took time.
Is it possible to achieve this in any way?

"(unless you are sending less than 8k in the response)"
I dont think this is working. I tried a file where content length came out
to be 10599 and 72 [<8K], but my header didnt get proper value in both
cases.


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

Reply via email to