On Tue, 4 Jan 2022, Nikša Baldun wrote:

I apologize for not commenting on the actual issue. However, after having the experience of writing a complex dialplan, I feel strongly compelled to say that it shouldn't be done at all. Any non-trivial call flow should be written in Fast AGI. I can't see any upside of using extensions.conf or AEL. Using a real programming language is considerably easier, faster and more powerful, all the necessary tools already exist and most importantly, execution is significantly faster. In my case, after rewriting my dialplan in Python, call preparation time fell from 2.5 seconds to a mere 50 milliseconds.

+1

Although, if you write your AGIs in a compiled language, a mix of dialplan and AGI is performant. One of my dialplans invokes a half dozen AGIs before the first prompt and nobody has ever complained about a delay.

An Asterisk lint / validator would be a good 'pre-flight' check before pushing out to production.

My first thought was that it should be an external tool, but a couple of my recent dialplans have been in AEL so maybe an internal tool does make sense.

Unfortunately, I do [ab]use channel variables extensively. Some of my dialplans create thousands of channel variables per call. Almost every sound file reference has at least 1 channel variable. Some variable references have nested variable names like:

        set(PER-MINUTE=${PRODUCT-${EXTEN}-PER-MINUTE})

and

        goto(${PRODUCT-${EXTEN}-APPLICATION},s,1)

--
Thanks in advance,
-------------------------------------------------------------------------
Steve Edwards       sedwa...@sedwards.com      Voice: +1-760-468-3867 PST
            https://www.linkedin.com/in/steve-edwards-4244281
-- 
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

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

Reply via email to