[asterisk-dev] Reverse Inheritance
John Todd
jtodd at digium.com
Tue Nov 11 16:09:29 CST 2008
On Nov 11, 2008, at 9:48 AM, Richard Mudgett wrote:
> Tilghman Lesher wrote:
>
>> I was thinking that it should happen exactly once, at the end of a
>> bridge.
>>
>> So what happens when Dial() creates three channels, and one of them
>> sets
>> a reverse-inheritance variable, but then is not the channel who
>> answers
>> and thus never gets bridged?
>>
>> Is this facility going to be *only* applicable to bridged channels?
>> If
>> so, it will need to be very clearly documented that way. If that is
>> the
>> case, then the 'multilevel' version could only ever apply to Local
>> channels, since that is the only method of having more than one
>> bridge
>> in the chain of inheritance.
>
> This idea could be useful for CCBS/CCNR to pass back a call completion
> record ID. However, that call will never reach the bridged state.
>
> Richard
I too am somewhat uncomfortable have variables "meaningful" only after
a channel is bridged and terminated - that seems to be very
inconsistent and will lead to all sorts of strange gymnastics again to
move variables back up to the parent channel for cases where one wants
to get preliminary data before the end of a bridge, or even before the
bridge is set up. If the call is "split" into multiple different
channels (i.e.: Dial(Local/foo&Local/bar) ) then I think I would be
comfortable with values changing immediately upon their being set in
the child channels, and the "last in" will be the current value. If
two channels "fight" over a value and re-set it back and forth, then
that is OK - perhaps that is desired in many cases, actually.
Give the dialplan administrator some rope here - they can make a
hammock as well as a noose out of it. If there is truly a desire to
set different values in different children, then use an identifier of
some type and let each channel set their own named value based on $
{EXTEN} as part of the variable name - pretty trivial to do. In any
case, I think the corner case is split channels, but the majority of
the time it'll be to single channels, and having values set only at
the end of a bridge will I think be frustrating to the usefulness of
this method in many cases.
PS: The "+" and "-" leading character idea seems to have few
proponents; I really don't care what way it's indicated. "^" is fine
with me.
JT
---
John Todd
jtodd at digium.com +1-256-428-6083
Asterisk Open Source Community Director
More information about the asterisk-dev
mailing list