[asterisk-dev] [Code Review] AST-33: Create a list of channel variables to be posted within AMI call events

Tilghman Lesher tlesher at digium.com
Sat Sep 26 23:01:40 CDT 2009


On Saturday 26 September 2009 07:22:45 Stefan Reuter wrote:
> Tilghman Lesher wrote:
> >>>>>> Channel1Var-SV_OWNER: a1101
> >>>>>> Channel1Var-SV_PEER: a1116
> >>>>>> Channel1Var-DISPLAY_URL:
> >>>>
> >>>> And in chan_sip we have
> >>>>
> >>>> astman_append(s, "ChanVariable: %s=%s\r\n", v->name, v->value);
> >>
> >> I don't understand you. It's a manager header that we use to display
> >> channel variables.
> >> We have a policy of not adding new headers if we already have one we
> >> use.
> >
> > Also, I'm pretty sure the Java implementation guys would prefer that we
> > make each header within an event completely unique, otherwise it breaks
> > their implementation.
>
> As one of the Java implementation guys I can add:
>
> The syntax
> Variable: var1=val1
> Variable: var2=val2
>
> is already supported in Asterisk-Java and works fine. In Asterisk-Java
> this translates to a Map called "variable" which contains
> var1 -> val1
> var2 -> val2
>
> So a syntax like
>
> Channel1Var: SV_OWNER=a1101
> Channel1Var: SV_PEER=a1116
> Channel1Var: DISPLAY_URL=
> Channel2Var: SV_OWNER=xyz
>
> would work pretty well for us.

I'm fine with that.  OEJ?

-- 
Tilghman Lesher
Digium, Inc. | Senior Software Developer
twitter: Corydon76 | IRC: Corydon76-dig (Freenode)
Check us out at: www.digium.com & www.asterisk.org



More information about the asterisk-dev mailing list