[asterisk-dev] channel name uniqueness

Atis Lezdins atis at iq-labs.net
Wed May 20 11:33:39 CDT 2009


On Wed, May 20, 2009 at 6:50 PM, Tim Ringenbach
<tim.ringenbach at gmail.com> wrote:
> On Mon, May 18, 2009 at 3:39 PM, Russell Bryant <russell at digium.com> wrote:
>>
>> The unique ID field on a channel is what uniquely identifies it from
>> others that had the same name.  The unique ID field is a monotonically
>> increasing integer, a timestamp, and optionally, a system name.
>>
>
> I did recently notice that the unique ID isn't copied during a channel masq
> and had been wondering if that was intentional. For what I was doing, it
> would have been much more convenient if it did copy.  The way it is now, the
> same channel name (e.g. SIP/foo-xxxx), representing the same actual call
> leg, will change uniqueid's (because it isn't copied into the channel struct
> on masq) during the lifetime of the call if certain events happen.
>
> Is that on purpose or an oversite? If it's intentional, you might want to
> add that quirk to the documentation.

That's exactly how it was designed.

There is going to be LinkedID soon (perhaps it's already merged in
some 1.6.x branch), that will basically be uniqueid of first channel
for a call. For now, You can just do

if ("${call_id}"="") Set(__call_id=${UNIQUEID});

Regards,
Atis


>
> --Tim
>
> _______________________________________________
> --Bandwidth and Colocation Provided by http://www.api-digital.com--
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-dev
>



-- 
Atis Lezdins,
VoIP Project Manager / Developer,
IQ Labs Inc,
atis at iq-labs.net
Skype: atis.lezdins
Cell Phone: +371 28806004
Cell Phone: +1 800 7300689
Work phone: +1 800 7502835



More information about the asterisk-dev mailing list