tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Edward Dowgiallo" <eddowgia...@gmail.com>
Subject Re: How can Servlet detect lost of connection to client?
Date Sat, 27 Sep 2008 22:56:36 GMT
How about putting in a lifecycle listener for Session destruction?

Ed

On Sat, Sep 27, 2008 at 6:14 PM, Martin Gainty <mgainty@hotmail.com> wrote:

>
> agreed.. I would definitely try that solution first
>
> also you may want to use a different connector (such as NIOConnector..)
> that supports Events
> if you keep in mind your client's browser will not display anything until
> the entire request is complete. so write a client application for your
> cometProcessor, to test how it works
> details at
> http://people.apache.org/~fhanik/http.html<http://people.apache.org/%7Efhanik/http.html>
>
> a rather elaborate example is located here
>
> http://www.ibm.com/developerworks/websphere/library/techarticles/0809_vamsi/0809_vamsi.html#15.Creating%20an%20NIO%20Connector|outline<http://www.ibm.com/developerworks/websphere/library/techarticles/0809_vamsi/0809_vamsi.html#15.Creating%20an%20NIO%20Connector%7Coutline>
>
> realising the asynchronous event model uses the comet processor
>
> http://tomcat.apache.org/tomcat-6.0-doc/api/org/apache/catalina/CometProcessor.html
>
> a more complete example is available here
>
> http://stackoverflow.com/questions/109294/are-writes-from-within-a-tomcat-6-cometprocessor-non-blocking
>
> filip and bill have been doing the most work on this Processor so i would
> ping them for more information..
>
> Dziekuje
> Martin
> ______________________________________________
> Disclaimer and confidentiality note
> Everything in this e-mail and any attachments relates to the official
> business of Sender. This transmission is of a confidential nature and Sender
> does not endorse distribution to any party other than intended recipient.
> Sender does not necessarily endorse content contained within this
> transmission.
>
>
> > Date: Sat, 27 Sep 2008 23:21:00 +0200
> > From: miki@ceti.pl
> > To: users@tomcat.apache.org
> > Subject: Re: How can Servlet detect lost of connection to client?
> >
> > 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
> >
>
> _________________________________________________________________
> See how Windows Mobile brings your life together—at home, work, or on the
> go.
> http://clk.atdmt.com/MRT/go/msnnkwxp1020093182mrt/direct/01/
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message