Salut,
Survivant 00 wrote:
> there is a way to disabled to timeout ? In my application the
> connections have to stay open around 8-10 hours without deconnection..
> it's a real-time stock application.. we can't accept to be disconnected.
Just to makes sure. Are you using Grizzly Comet or just the NIO
framework (too much travel this week :-)) ? If you are using the NIO
framework, you will need to disable the timeout to avoid Grizzly closing
it after 30 seconds idle times.
>
> and by the way John.. thanks for your reply on my demo. I'll check it
> this weekend.
Yes big big thanks to John!!!
A+
-- Jeanfrancois
>
>
>
>
> 2008/6/5 John ROM <snake-john_at_gmx.de <mailto:snake-john_at_gmx.de>>:
>
> Hi,
> in grizzly the default on an idle connection is set to 30 seconds.
>
> if you need longer connections you need to have code like this ,of
> course on both sides
> client and on server
>
> TCPSelectorHandler tcpSelectorHandler = new TCPSelectorHandler();
>
> DefaultSelectionKeyHandler keyHandler = new
> DefaultSelectionKeyHandler();
> //keep connection for example for 30 minutes or whatever you need
> keyHandler.setTimeout(30 * 1000 * 60);
> tcpSelectorHandler.setSelectionKeyHandler(keyHandler);
> controller.addSelectorHandler(selectorHandler);
>
> does this help?
>
> Greetings john
>
> --
> Psssst! Schon vom neuen GMX MultiMessenger gehört?
> Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_grizzly.dev.java.net
> <mailto:users-unsubscribe_at_grizzly.dev.java.net>
> For additional commands, e-mail: users-help_at_grizzly.dev.java.net
> <mailto:users-help_at_grizzly.dev.java.net>
>
>