[Asterisk-Users] RE: Explicit Dialplan Exit

Michael Collins mcollins at fcnetwork.com
Wed May 31 10:14:37 MST 2006


Do you have a before-and-after example?  I think we'd like to see a
sample of a context & extensions with hard-coded priorities and the
subsequent translation into unnumbered priorities with labels.  There
are some creative people out there who might have the key to getting
your dialplan simplified without losing its power.

 

-MC

 

  _____  

From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Douglas
Garstang
Sent: Wednesday, May 31, 2006 9:27 AM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: [Asterisk-Users] RE: Explicit Dialplan Exit

 

Eh, I'm thinking I don't like labels very much. They aren't all they are
cracked up to be.

 

Previously, using extensions of the format extension-function, like
2944000-open or 2944000-closed for example, I could break up an
extension into logical units based on function, and it made sense. By
exclusively using labels, everthing is in the one extension and it isn't
as easy to read at a glance. There's also the chance that statements
from one section could over-run into another.

 

or... am I missing something?

 

Doug

-----Original Message-----
From: Douglas Garstang 
Sent: Wednesday, May 31, 2006 10:06 AM
To: 'Asterisk Users Mailing List - Non-Commercial Discussion'
Subject: Explicit Dialplan Exit

So, I've kind of converted my dialplan from:

 

exten =>
custcare,1,GotoIfTime(8:00-17:00|mon-fri|*|*?acd_one_queue,custcare-open
,1)
exten => custcare,2,Goto(custcare-closed,1)

 

exten => custcare-open,1....

exten => custcare-open,99....

 

exten => custcare-closed,1....

exten => custcare-closed,99....

 

to:

 

exten => custcare,1,GotoIfTime(8:00-17:00|mon-fri|*|*?custcare_open)
exten => custcare,n,Goto(custcare-closed,1)

 

exten => custcare,n(open_start),...

exten => custcare,n...

 

exten => custcare,n(closed_start)...

exten => custcare,n...

 

I don't like having those final statements in each block. Previously,
execution would implicitly end because there was no priorities left in
each extension. Now however, everything is in one extension and I can't
be sure that execution will not continue at the end of a section
(open,closed etc). Is there some sort of explicit dialplan command that
stops execution and immediately ends the dialplan? Something like
MacroExit() in a macro.... Can't see it in the docs.

 

Doug.

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060531/6365ccd9/attachment.htm


More information about the asterisk-users mailing list