[asterisk-users] AGI asterisk high balance
Grey Man
greymanvoip at gmail.com
Fri May 9 03:45:09 CDT 2008
On Fri, May 9, 2008 at 5:19 AM, Al Baker <bwentdg at pipeline.com> wrote:
> I think his connect/disconnect is going to take far longer than his 3
> queries.
> The fact that Asterisk doesn't support sustained MySQL connection from
> the DialPlan
> is in fact quite a big deal that Digium seems to have its head in the
> sand about.
> And one of those things that SHOULD come up in those "Is * Ready For
> Prime Time Threads"
I would not agree with that. Asterisk's primary purpose as a PBX is
moving the media around and doing lots of clever things with it.
Asterisk has lots of ways to do inter-process communication (AGI,
FastAGI, MAPI, Dialplan Apps) so the fact that it may not be optimised
for a purpose to what most of us use it for when there are good
options available to do the same thing does not hold water.
Now if you were to get me started on Asterisk and its CDR's I would
throw in a moan or two ;-).
In relation to timing how long the rates lookups take it's as simple
as taking a timestamp at the start of your application and suntracting
it from the timestamp when you're finished and spitting it out to a
log file. As far as the lookup taking too long the application logic I
use manages to lookup the rate using a combination of regular
expressions and longet matches as well as interogate the customers
call plans of which they can have multiple with differnet combinations
of destinations in plans and pay as you go balances and return the
time for the call in well under 100ms. The logic is in C# but even so
I wouldn't expect Perl to be slow. I'd suggest timing how long your
database calls are. At one point the credit checks I was doing started
to go up over 1 second and it was purely down to the load on the
database (Postgresql). Getting a bigger server fixed it.
Regards,
Greyman.
More information about the asterisk-users
mailing list