tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Barker" <wbar...@wilshire.com>
Subject Re: How can Servlet detect lost of connection to client?
Date Sat, 27 Sep 2008 23:06:00 GMT

"Ming Deng" <mingdeng2004@gmail.com> wrote in message 
news:a79731c20809271424m556610e9n2a761923658fc9e1@mail.gmail.com...
> Even though servlet can't detect that kind of events, will Tomcat be aware
> of such events in its internal process?
>

Generally, no Tomcat won't be aware of such an event until it attempts to 
write on the Socket.  It doesn't pay attention to the Socket while the 
Servlet is processing.

>
>
> On Sat, Sep 27, 2008 at 5:21 PM, Mikolaj Rydzewski <miki@ceti.pl> wrote:
>
>> Ming Deng wrote:
>>
>>> If a client HTTP request takes some time to process on the servlet side,
>>> it
>>> is possible that the Tomcat can lose connection to the client in the
>>> middle
>>> of this processing time, due to various reasons, for example the client
>>> quit. How can servlet detect such event so it can terminate the server
>>> side
>>> processing which is not needed any more
>>>
>> I believe that the only way is to receive IOException while writing to
>> respone.
>>
>> --
>> Mikolaj Rydzewski <miki@ceti.pl>
>>
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
> 




---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message