> On Mon, Jun 23, 2008 at 12:54 PM, Douglas Garstang <[EMAIL PROTECTED]> 
> wrote:

>> I'm about to build a complex IVR with Asterisk.
>>
>> Having done it a few times with the dial plan, I know it's going to be 
>> pretty ugly. What are my other options? I guess I could do it in 
>> AGI/FastAGI. What about VxML (about which I know almost nothing...)?
>>
>> Using Asterisk 1.2

> From: Steve Totaro <[EMAIL PROTECTED]>
>
> FastAGI is a good bet.  You can patch it to jump N+101 so you can have 
> failover in case the box hosting the AGI is unreachable, it will jump, 
> instead of the default of just failing and halting.
>
> It also offloads the processing to a different box.

On Mon, 23 Jun 2008, Douglas Garstang wrote:

> Right, except now I have to go write a multi-threaded, redundant FastAGI 
> server in python (euww, hate java). That replaces the effort of doing it 
> in the dial-plan with the effort required for a more complex application 
> + the effort required to make it redundant. Asterisk 1.2 also does not 
> recover from a failure to connect to a FastAGI server. When it fails to 
> connect, the current call just bombs out. No recovery possible.

Then don't do it (fastagi()).

Even a POC computer can do hundreds of "normal" AGIs per second.

If your load isn't massive, agi() should be fine. If AGIs truly (and 
demonstrably) are the bottleneck, almost all of your work should be 
reusable as FastAGI. If your load is expected to be massive, C would be a 
better choice for your FastAGI server anyway. Or, throw a lot more 
hardware at the problem.

I would build it this way:

1) Design the dialplan logically so it is understandable and maintainable.

2) Code up the AGIs in whatever language you are comfortable. I would use 
C, but that's what I'm most comfortable with.

3) Confirm everything works like you think it should.

4) Measure to identify where the real bottlenecks are.

5) Attack the top 1 or 2 bottlenecks. The solution may be:

a) Recode an AGI in C.

b) Re-implement an AGI as fastagi() on the same server.

c) Re-implement an AGI as fastagi() on another server.

6) Go to step 3

Thanks in advance,
------------------------------------------------------------------------
Steve Edwards      [EMAIL PROTECTED]      Voice: +1-760-468-3867 PST
Newline                                             Fax: +1-760-731-3000

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

AstriCon 2008 - September 22 - 25 Phoenix, Arizona
Register Now: http://www.astricon.net

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

Reply via email to