You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2002/10/29 20:05:11 UTC
DO NOT REPLY [Bug 14059] New: -
HTP Response does not respond correctly to flush()
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=14059>.
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=14059
HTP Response does not respond correctly to flush()
Summary: HTP Response does not respond correctly to flush()
Product: Tomcat 4
Version: 4.1.12
Platform: PC
OS/Version: Windows NT/2K
Status: NEW
Severity: Major
Priority: Other
Component: Connector:Coyote HTTP/1.1
AssignedTo: tomcat-dev@jakarta.apache.org
ReportedBy: jpettens@rochester.rr.com
The code below processes a servlet response. In TC4.0.6 the client does
get the response message at the flush(). The sleep does not effect
the delivery.
In TC 4.1.12, the output does not get delivered until after the code gets back
into the area around:
org.apache.coyote.tomcat4.CoyoteAdapter.service(org.apache.coyote.Request,
org.apache.coyote.Response) line: 226
Bottom line is the flush() has no effect on getting the data out of the stream.
My normal client is java code, however, I have reproduced the problem
using this code chunk using either mozilla or IE6 in place of the clients.
try {
logger.debug( "Release requestor" );
response.setContentType( "text/plain; charset=ISO-8859-1" );
PrintWriter out = response.getWriter();
out.println( "OK" );
out.flush();
out.close(); // client should get "OK" message at this time
logger.debug( "Release requestor - done" );
String readQueue = request.getParameter( "readQueue" );
logger.debug( "Sleeping" );
Thread.sleep(6000);
logger.debug( "awake" );
// Pull off parms passed and exec ReadCntl
} catch ( Exception e ) {
logger.error("Unexpected error", e);
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>