Are there any features in asterisk that might be used to effect a background dial task? I want to be able to start a Dial task running, in chich the execution can be automated via DTMF tones (e.g., voicemail retrieval), but not block the originating thread of execution. The dial plan or AGI containing the Dial command should proceed on to the next step. I'll arrange some kind of rendezvous later on. As far as I can tell, I'm on my own to build this capability through some sort of daemon and the manager API or my own IPC mechanism. I'd really hoped for some higher level of abstraction from within Asterisk to accomplish this. Am I missing something in Asterisk that will make this easier to accomplish? Are there any publically available examples of this kind of application? Anybody got any ideas for nifty tricks to get this done? Thanks in advance. John
Eric "ManxPower" Wieling
2005-Nov-13 16:29 UTC
[Asterisk-Users] How to do "asynchrononous" Dial?
John Biundo wrote:> Are there any features in asterisk that might be used to effect a > background dial task? > > I want to be able to start a Dial task running, in chich the execution > can be automated via DTMF tones (e.g., voicemail retrieval), but not > block the originating thread of execution. The dial plan or AGI > containing the Dial command should proceed on to the next step. I'll > arrange some kind of rendezvous later on. > > As far as I can tell, I'm on my own to build this capability through > some sort of daemon and the manager API or my own IPC mechanism. I'd > really hoped for some higher level of abstraction from within Asterisk > to accomplish this. > > Am I missing something in Asterisk that will make this easier to > accomplish? > > Are there any publically available examples of this kind of application? > > Anybody got any ideas for nifty tricks to get this done?See sample.call in the Asterisk source directory and .call files on the Wiki. Sounds like you want Asterisk to call a person when a voicemail is left and allow the person to get their voicemail during the notification call.
So what you ant to do is FORK and kick the first proc into background. You may be able to do this with the Local Channel... Alex> -----Original Message----- > From: asterisk-users-bounces@lists.digium.com > [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of > John Biundo > Sent: Sunday, November 13, 2005 8:24 PM > To: Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [Asterisk-Users] How to do "asynchrononous" Dial? > > Thanks for the suggestion. > > Sorry if my requirements weren't clear. I need a general > purpose "run this in the background" capability. The > voicemail was simply an example, and probably a bad one. I > want the Dial command to go off on a separate thread so the > main thread can continue. What happens in that second thread > is arbitrary. I'll deal with getting "data" in and out of > that second thread as appropriate - perhaps by dropping stuff > in a database or some other synchronization method. The key > is that while that second "background task" is executing, the > initial thread of execution doesn't block and can continue > running arbitrary Asterisk applications. > > > See sample.call in the Asterisk source directory and .call files on > > the Wiki. Sounds like you want Asterisk to call a person when a > > voicemail is left and allow the person to get their > voicemail during > > the notification call. > > > > _______________________________________________ > --Bandwidth and Colocation sponsored by Easynews.com -- > > Asterisk-Users mailing list > Asterisk-Users@lists.digium.com > http://lists.digium.com/mailman/listinfo/asterisk-users > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > >