[Asterisk-Dev] Wish List / Brain Storm from AstriCon

Benjamin on Asterisk Mailing Lists benjk.on.asterisk.ml at gmail.com
Wed Sep 29 06:47:11 MST 2004


On Wed, 29 Sep 2004 15:11:49 +0200, Arnaud Pignard <apignard at frontier.fr> wrote:
> exten => s,auto,[Some App] (will be convert to 1)
> exten => s,auto,[Some App] (will be convert to 2)
> 
> The numerotation will be done at the parsing of extention.conf
> And as double is already check, add after this line like this won't make
> any trouble :
> exten => s,3,[Some App]

That won't work at all. You seem to forget that there are things such
as Goto which need a discrete number.

For example:

[UK-incoming]
exten => 08705551234,1,NoOp(incoming call via ${EXTEN})
exten => 08705551234,2,Goto(incoming,s,2)
;
[incoming]
exten => s,1,NoOp(incoming call)
exten => s,2,Dial(${RECEPTION},60,r)
...

How would your auto-number assignment algorithm figure out that it has
to insert 2 into the Goto statement in the first context?

Also, what about the priority+101 rule for exceptions? How would the
algorithm know in which line to add 101 to the priority? And how would
you deal with references to those lines?


Let's face it. Automatic numbering is far more difficult to realise
than it may look at first. You will either need to get rid of
numbering altogether because we all know that Goto is evil anyway, or,
if you don't want to go as far as that, you will need to introduce
Goto to named labels. If you don't want to do neither, you will have
to put up with the status quo.

rgds
benjk

-- 
Sunrise Telephone Systems, 9F Shibuya Daikyo Bldg., 1-13-5 Shibuya,
Tokyo, Japan.

NB: Spam filters in place. Messages unrelated to the * mailing lists
may get trashed.



More information about the asterisk-dev mailing list