tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Remy Maucherat <r...@apache.org>
Subject Re: Comet changes
Date Mon, 07 May 2007 14:28:34 GMT
Filip Hanik - Dev Lists wrote:
>> - EOF as a new ComentEvent.EventSubType, subtype of 
>> CometEvent.EventType .END (will be called when the endpoint signals a 
>> read); after getting this event, the CometAdapter could automagically 
>> call CometEvent.disableReadPolling() to avoid problems if the client 
>> somehow sends additional bytes (they don't belong to this request) 
> how could the client send "additional bytes" when an EOF happens. EOF 
> would only happen if the client disconnected, ie read() returns -1 on 
> the socket.

EOF (read returns -1) occurs when the entire body of the request has 
been read, and if additional read calls are made by Tomcat. For a 
disconnect, the result is an exception, not a -1. Additional bytes can 
still be present if the client is slightly broken (it could send some 
CRLFs) or if it uses pipelining.

Rémy

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


Mime
View raw message