Re: [asterisk-users] AGI STREAM FILE and not blocking execution

2009-10-22 Thread Patrick
Hello guys,

Thank you for your answers

I've seen in the ExternalIVR command :

If the child process dies, ExternalIVR() will notice this and hang up
the channel immediately (and also send a message to the log).

That's not what I'd like, I want that if the process finish gracefully
that the AGI scripts continues.

I guess in this case that a new thread is the most convenient way, or,
by any chance, do you know if asterisk will stack commands if a new
agi command is received while the stream file is not finished ?

Thanks in advance,
Patrick



On Thu, Oct 22, 2009 at 17:39, Jared Smith  wrote:
> On Thu, 2009-10-22 at 08:43 +0200, Patrick wrote:
>> I'm wondering if I can take benefits of long prompts to compute in the
>> background the next step to be performed by Asterisk.
>>
>> Do you know what will be the behavior of asterisk if I send a STREAM
>> FILE command immediately followed by another command ? Will asterisk
>> stack commands or will it stop the first one to execute the second one
>> ?
>
> If you want non-blocking (asynchronous) commands, check out the
> ExternalIVR interface instead of using AGI.
>
>
>
> --
> Jared Smith
> Training Manager
> Digium, Inc.
>
>
> ___
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] AGI STREAM FILE and not blocking execution

2009-10-22 Thread Jared Smith
On Thu, 2009-10-22 at 08:43 +0200, Patrick wrote:
> I'm wondering if I can take benefits of long prompts to compute in the
> background the next step to be performed by Asterisk.
> 
> Do you know what will be the behavior of asterisk if I send a STREAM
> FILE command immediately followed by another command ? Will asterisk
> stack commands or will it stop the first one to execute the second one
> ?

If you want non-blocking (asynchronous) commands, check out the
ExternalIVR interface instead of using AGI.



-- 
Jared Smith
Training Manager
Digium, Inc.


___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] AGI STREAM FILE and not blocking execution

2009-10-22 Thread Steve Edwards
On Thu, 22 Oct 2009, Patrick wrote:

> I'm wondering if I can take benefits of long prompts to compute in the 
> background the next step to be performed by Asterisk.

I did this a few years ago so that I could process a credit card 
authorization request while the "Please wait..." prompt was playing.

I did it by creating a new thread (in C) in my AGI to play the prompt.

Usually I get the card response before the prompt finishes playing so to 
the caller it's "instantaneous."

-- 
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] AGI STREAM FILE and not blocking execution

2009-10-21 Thread Patrick
Hello,

I'm wondering if I can take benefits of long prompts to compute in the
background the next step to be performed by Asterisk.

Do you know what will be the behavior of asterisk if I send a STREAM
FILE command immediately followed by another command ? Will asterisk
stack commands or will it stop the first one to execute the second one
?

If stops, is there any AGI library that handles this kind of behavior
or should I code it myself using callback methods ?

Thanks in advance for your answer

Patrick

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users