Thread: [Asterisk-java-users] Automatically start a pingthread when socket read timeout is set
Brought to you by:
srt
From: Gaëtan M. <gm...@ea...> - 2008-03-25 15:27:07
Attachments:
ManagerConnectionImplPingThread.patch
|
Hi Stefan What do you think of automatically starting a pingthread on the connection if the client sets the socket read timeout, so the client code needn't bother with a reference to a thread ? Here is a micro-patch; Kind regards Gaetan |
From: Stefan R. <ste...@re...> - 2008-03-25 18:54:11
Attachments:
signature.asc
|
Hi, the live API (org.asteriskjava.live.AsteriskServer and co) already does that. My idea is that the live API provides all kinds of convenient stuff on top of the Manager API but the Manager API itself doe not do anything unexpected and only what is absolutly required. When using the live API and you still require to access the low level Manager API methods you can retrieve the ManagerConnection from the DefaultAsteriskServer. Does that make sense? =Stefan Gaëtan Minet wrote: > Hi Stefan > > What do you think of automatically starting a pingthread on the > connection if the client sets the socket read timeout, so the client > code needn't bother with a reference to a thread ? > Here is a micro-patch; > > Kind regards > Gaetan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |
From: Gaëtan M. <gm...@ea...> - 2008-03-25 19:11:46
|
Hi Stefan, Granted you're right, that convenient function would be more appropriate in the live api, this wasn't intended. Gaetan On 25/03/2008, at 19:53, Stefan Reuter wrote: > Hi, > > the live API (org.asteriskjava.live.AsteriskServer and co) already > does > that. My idea is that the live API provides all kinds of convenient > stuff on top of the Manager API but the Manager API itself doe not do > anything unexpected and only what is absolutly required. > When using the live API and you still require to access the low level > Manager API methods you can retrieve the ManagerConnection from the > DefaultAsteriskServer. > > Does that make sense? > > =Stefan > > Gaëtan Minet wrote: >> Hi Stefan >> >> What do you think of automatically starting a pingthread on the >> connection if the client sets the socket read timeout, so the client >> code needn't bother with a reference to a thread ? >> Here is a micro-patch; >> >> Kind regards >> Gaetan > > -- > reuter network consulting > Neusser Str. 110 > 50760 Koeln > Germany > Telefon: +49 221 1305699-0 > Telefax: +49 221 1305699-90 > E-Mail: ste...@re... > Jabber: ste...@re... > WWW: http://www.reucon.com > > Steuernummern 215/5140/1791 USt-IdNr. DE220701760 > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users |
From: Stefan R. <ste...@re...> - 2008-03-25 19:20:19
Attachments:
signature.asc
|
Hi Gaëtan, And it's already there :) Try it and report back if you encounter any trouble with it. =Stefan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |
From: Gaëtan M. <gm...@ea...> - 2008-03-25 19:42:46
|
Stefan, I feel stupid, but I cannot find the code your'e refering to. Any pointer ? Gaetan On 25/03/2008, at 20:20, Stefan Reuter wrote: > Hi Gaëtan, > > And it's already there :) > Try it and report back if you encounter any trouble with it. > > =Stefan > > -- > reuter network consulting > Neusser Str. 110 > 50760 Koeln > Germany > Telefon: +49 221 1305699-0 > Telefax: +49 221 1305699-90 > E-Mail: ste...@re... > Jabber: ste...@re... > WWW: http://www.reucon.com > > Steuernummern 215/5140/1791 USt-IdNr. DE220701760 > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users |
From: Stefan R. <ste...@re...> - 2008-03-25 19:48:55
Attachments:
signature.asc
|
Gaëtan Minet wrote: > I feel stupid, but I cannot find the code your'e refering to. Any > pointer ? Uhh sorry, no reason to feel sorry. It seems I've been dreaming of this... could you move your patch to live? Thanks for your feedback and sorry again, Stefan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |
From: Stefan R. <ste...@re...> - 2008-03-25 19:54:41
Attachments:
signature.asc
|
Stefan Reuter wrote: > Uhh sorry, no reason to feel sorry. It seems I've been dreaming of no reason to feel stupid of course :) =Stefan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |
From: Gaëtan M. <gm...@ea...> - 2008-04-01 14:14:01
|
Hi Stefan As usual, sorry for the delay :) Here is a tiny patch that starts a pingthread when an AsteriskServer is given a ManagerConnection whose socketReadTimeout>0 and stop it at shutdown(); However I don't really like it as it seems a bit misplaced and orthogonal to me. Maybe it whould be better to hide this in DefaultAsteriskServer ? But then people working directly with AsteriskServerImpl like me wouldn't even use it. Or what about a ManagerConnection subclass / implementation? After all, this is just another interface implementation and the asterisk server needn't know about this PingThread thing. Regards Gaetan On 25/03/2008, at 20:54, Stefan Reuter wrote: > Stefan Reuter wrote: >> Uhh sorry, no reason to feel sorry. It seems I've been dreaming of > > no reason to feel stupid of course :) > > =Stefan > > -- > reuter network consulting > Neusser Str. 110 > 50760 Koeln > Germany > Telefon: +49 221 1305699-0 > Telefax: +49 221 1305699-90 > E-Mail: ste...@re... > Jabber: ste...@re... > WWW: http://www.reucon.com > > Steuernummern 215/5140/1791 USt-IdNr. DE220701760 > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/_______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users |