beonice
2005-Mar-07 15:21 UTC
[Asterisk-Users] Question about AGI vs. FastAGI vs. straight C/DB development
Folks, I want to build a custom IVR for my setup. I've got it working (well, the bells and whistles are not there yet, but the basic stuff works) using AGI, but I'm worried about how well this will scale. I've seen references to FastAGI, and presumably this will be more efficient. Question, though: how well do either of these (AGI or FastAGI) scale if my system is handling a large number of simultaneous calls? I'm assuming that even with FastAGI, there's going to be some CPU overhead that will increase as the number of simultaneous calls increases. Would it make more sense to write a custom application in C instead, designing it to work sort-of like the built-in app_voicemail.c and others? I do know C, but is it worth the effort in terms of ROI? :) I'd like to figure this out in advance rather than after all my customers (hopefully there _will_ be customers) start yelling at me about performance issues. :) Cheers, Maya __________________________________ Celebrate Yahoo!'s 10th Birthday! Yahoo! Netrospective: 100 Moments of the Web http://birthday.yahoo.com/netrospective/
Steven Critchfield
2005-Mar-07 16:07 UTC
[Asterisk-Users] Question about AGI vs. FastAGI vs. straight C/DB development
On Mon, 2005-03-07 at 14:21 -0800, beonice wrote:> Folks, > > I want to build a custom IVR for my setup. I've got it > working (well, the bells and whistles are not there > yet, but the basic stuff works) using AGI, but I'm > worried about how well this will scale. > > I've seen references to FastAGI, and presumably this > will be more efficient. > > Question, though: how well do either of these (AGI or > FastAGI) scale if my system is handling a large number > of simultaneous calls? I'm assuming that even with > FastAGI, there's going to be some CPU overhead that > will increase as the number of simultaneous calls > increases. > > Would it make more sense to write a custom application > in C instead, designing it to work sort-of like the > built-in app_voicemail.c and others? I do know C, but > is it worth the effort in terms of ROI? :) > > I'd like to figure this out in advance rather than > after all my customers (hopefully there _will_ be > customers) start yelling at me about performance > issues. :)You said a magic word there, customers. You need to become versed in the ins and outs of licensing. If you write it in C and distribute it, you must also offer to those you distribute asterisk your modifications and linked in code. For AGI and FastAGI, it isn't linked to GPL code in asterisk and therefore is sheltered from the GPL license of asterisk. But then you need to verify you aren't using any libraries that are distributed under a GPL license or you would also have to open source your code upon distribution. FastAGI offers faster initial response times than AGI as it will most likely already be running and ready to accept a new call. FastAGI should also be capable of being load balanced if that process is doing too much work to be responsive upon scaling. AGI is not capable of being run from a different machine. -- Steven Critchfield <critch@basesys.com>
beonice
2005-Mar-07 18:17 UTC
[Asterisk-Users] Question about AGI vs. FastAGI vs. straight C/DB development
--- Steven Critchfield <critch@basesys.com> wrote:> On Mon, 2005-03-07 at 14:21 -0800, beonice wrote:--- snip ---> > Would it make more sense to write a custom > application > > in C instead, designing it to work sort-of like > the > > built-in app_voicemail.c and others? I do know C, > but > > is it worth the effort in terms of ROI? :) > > > > I'd like to figure this out in advance rather than > > after all my customers (hopefully there _will_ be > > customers) start yelling at me about performance > > issues. :) > > You said a magic word there, customers. You need to > become versed in the > ins and outs of licensing. If you write it in C and > distribute it, you > must also offer to those you distribute asterisk > your modifications and > linked in code.Hmm. I'm not going to be distributing this, it'll be an in-house application, for my eyes only. :) The customers will merely be using the in-house server. So GPL or not would not be an issue. Robustness, scaleability and ROI definitely are the issues I'm interested in. Again, the licensing issues for AGI or FastAGI using any Asterisk libraries should not be an issue either. --- snipped some of Steven's response ---> FastAGI offers faster initial response times than > AGI as it will most > likely already be running and ready to accept a new > call. FastAGI should > also be capable of being load balanced if that > process is doing too much > work to be responsive upon scaling. AGI is not > capable of being run from > a different machine.Okay, so it looks like AGI itself will not be worth pursuing. That's okay, at least I have a handle on what I'm doing now. So, FastAGI or straight C? I just want something that's easy to write. FastAGI will have to be wrapped around Asterisk commands, so I'm anticipating a slight overhead there, but if it's really not that much slower, it may be faster to get the IVR code up and running. Opinions? Would any of you bother writing an IVR-only application (like the app_voicemail application) in C? Why or why not? Thanks, Maya __________________________________ Celebrate Yahoo!'s 10th Birthday! Yahoo! Netrospective: 100 Moments of the Web http://birthday.yahoo.com/netrospective/