HttpServletResponse « Tomcat « JSP-Servlet Q&A





1. How to pretty print HttpServletRequest and HttpServletResponse    stackoverflow.com

I would like to add logging of requests and responses to a Java webapp which I am running within Tomcat 6. The intention is to produce a log file with output ...

2. tomcat 6 . How does HttpServletResponse make browsers react immediately , not have done response.getOutputStream().close()??    stackoverflow.com

This is the code in my servlet:

while( bytes....){//do read file to bytes
    response.getOutputStream().write(bytes);
    response.getOutputStream().flush();
    log4j.debug(response.isCommitted());  // out  true.
}
If ...