[asterisk-dev] [Code Review]: Triggers dialplan actions when specific CONTROL_FRAMES are detected on a channel
Matthew Jordan
mjordan at digium.com
Sun Jul 29 09:52:44 CDT 2012
----- Original Message -----
> From: "Pavel Troller" <patrol at sinus.cz>
> To: "Asterisk Developers Mailing List" <asterisk-dev at lists.digium.com>
> Sent: Saturday, July 28, 2012 11:09:22 PM
> Subject: Re: [asterisk-dev] [Code Review]: Triggers dialplan actions when specific CONTROL_FRAMES are detected on a
> channel
>
>
> The only thing I would like to do in the subroutine would be
> something like
> this:
>
> exten => s,1,GotoIf($[${DIALSTATUS} = "ANSWER"]?end)
> exten => s,n,Set(OVERLAP_DIGITS=${OVERLAP_DIGITS}${FRAME_DATA})
> exten => s,n(end),Return()
>
<snip>
>
> The contents of the OVERLAP_DIGITS variable would be then used at two
> places:
> 1) If the called party hangs up first, in continuation of the main
> dialplan
> (the 'g' flag is set for the Dial())
> 2) If the calling party hangs up first, in the 'h' extension.
>
> The variable would be used just to complete the CDR records and the
> Last Number
> Redial database entry.
>
You don't need this feature to accomplish this. You need something that
does this in the frame handling loop in Dial. It can accumulate the
DTMF digits itself (if overlap dialing for the call is enabled, via some
mechanism).
This patch is not the correct way to accomplish what you want to solve.
You can use a chainsaw to open a can of soup, but there are better tools
for the job.
> And this is the problem. The missing 1% is preventing to use the
> whole nice
> overlap dialling feature in the real telecom industry environment,
> making it
> just an "enthusiast's" one. A real operator (please believe me, I'm
> working for
> one, and trying to push Asterisk, wherever I can) really needs
> complete CDRs
> for several reasons, including Lawful Interception. A real PBX owner
> also
> requires this feature, to have the LNR feature fully working.
I'm not entirely sure that people in the "real telecom industry" don't
use overlap dialing, but okay. Perhaps the problem is pervasive. If it is,
and this is a needed feature that you'd like to see, then:
a) Propose the feature as an improvement to Asterisk at AstriDevCon, which
is where new features are discussed by the Asterisk developer community.
https://wiki.asterisk.org/wiki/display/AST/AstriDevCon
b) Alternatively, write the new feature and submit it for inclusion into
Asterisk. The patch can be attached to an issue in the issue tracker.
https://issues.asterisk.org/jira/
If you'd like to take on the patch that we're discussing and address the
concerns of the developers who have reviewed it, that would be a potential
starting point, although I'd maintain that it isn't needed to solve the
problem you want to solve.
c) Hire an open source developer to write the feature for you. You can
request development assistance on the asterisk-biz list.
> I fully agree, that this feature would require BIG BIG BIG caution from the
> users. But - you know - if you buy a knife, you also should be careful when
> using it. And the possibility to make yourself an injury doesn't prevent knives
> from being sold :-).
I wouldn't call this a knife; I'd call this a knife with a blade for a handle.
You could theoretically use it, but you're much more likely to cut yourself
in the process of doing so.
Again, as I said when I closed this review, if someone wants to maintain this
patch as it is and have people use it, that's fine. You're more then welcome
to do so. If someone wants to take this patch, make it so it handles putting
the channel in autoservice, and reply to the valid objections raised against
the patch by the developers who have reviewed it, that's also fine. It can be
re-reviewed and be a potential candidate for inclusion in another version of
Asterisk.
In its current incarnation, it is not in a state where it belongs in Asterisk 11.
Sorry.
--
Matthew Jordan
Digium, Inc. | Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at: http://digium.com & http://asterisk.org
More information about the asterisk-dev
mailing list