Hello,<br>
<br>
Race condition still happens with db function. bridge_uuid is undefined.<br>
I made a hack, added execute_on_bridge variable, and execute it on bridge.<br>
This way it works for me. I am sure this is not the best solution.<br>
Please take a look, maybe improve it.<br>
Or could you suggest any other solution for this?<br>
<br>
Thanks,<br>
Tamas <br><br><div><span class="gmail_quote">On 4/11/08, <b class="gmail_sendername">Anthony Minessale</b> <<a href="mailto:anthony.minessale@gmail.com">anthony.minessale@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I found a bug where some code to optimize for escaped strings not
needing expansion skipped the expansion which is not ok cos we need to
strip the \ in the result<br><br>Update to 8087 or newer and try my original suggestion.<br>
<br>By the way, this is probably a race condition waiting to happen because you are using a global var here.<br>You may want to consider using the db function instead.<br><br> <action application="db" data="insert/track_uuid/${caller_id_number}/${bridge_uuid}"/><br>
<br>
<action application="set" data="my_id=1234"/><br>
<action application="set" data="execute_on_answer="db insert/track_uuid/\${my_id}/\${bridge_uuid}"/><br><br>then later you can make an extension that expands<br>${db(select/track_uuid/1234)}<br>
<br>and it would be the bridge_uuid as inserted by the above execute_on answer and unique to the callers id<div><span class="e" id="q_1193e3996324e3d3_1"><br><br><br><br><br><div class="gmail_quote">On Fri, Apr 11, 2008 at 11:21 AM, Tamas Cseke <<a href="mailto:cstomi.levlist@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">cstomi.levlist@gmail.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hello,<br>
<br>
Thanks your help!<br>
<br>
I have problems with it.<br>
when i try<br>
<div><br>
<action application="set" data="execute_on_answer=set_global<br>
</div>spy_uuid=\${bridge_uuid}"/><br>
<br>
expand doesn't change its input, so the value of spy_uuid will be<br>
'\$bridge_uuid'.<br>
<br>
I can figure this out with<br>
<div><br>
<action application="set" data="execute_on_answer=set_global<br>
</div>spy_uuid=\${bridge_uuid}${foobar}"/><br>
<br>
In this case it is expanded to spy_uuid=${bridge_uuid}<br>
But on answer brigde_uuid is undefined.<br>
Is it any other solution for setting a global variable with the value of<br>
the bridge_uuid on answer?<br>
<br>
Thanks any help,<br>
Tamas<br>
<div><div></div><div><br>
<br>
<br>
<br>
<br>
> oops i meant \$<br>
><br>
> On Thu, Apr 10, 2008 at 4:24 PM, Anthony Minessale <<br>
> <a href="mailto:anthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">anthony.minessale@gmail.com</a>> wrote:<br>
><br>
><br>
>> try escaping the $ with /$<br>
>><br>
>><br>
>> On Thu, Apr 10, 2008 at 2:21 PM, Tamas Cseke <<a href="mailto:cstomi.levlist@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">cstomi.levlist@gmail.com</a>><br>
>> wrote:<br>
>><br>
>><br>
>>> Hello,<br>
>>><br>
>>> I would like to mark the uuid of the called channel for further process.<br>
>>> (Spying this channel with eavesdrop for other call)<br>
>>><br>
>>> i tried with the execute_on_answer variable but it doesn't suit for me.<br>
>>> I think the value of the var is evaluated immediately, when bridged_uuid<br>
>>> isn't set yet.<br>
>>> Could you advise a solution for this please, if there is?<br>
>>><br>
>>> Something like:<br>
>>> <action application="bridge" data="portaudio"/><br>
>>> <action application="set" data="execute_on_answer=set_global<br>
>>> spy_uuid=${bridged_uuid}"/><br>
>>><br>
>>> Thanks,<br>
>>> Tamas<br>
>>><br>
>>><br>
>>> On 4/2/08, Anthony Minessale <<a href="mailto:anthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">anthony.minessale@gmail.com</a>> wrote:<br>
>>><br>
>>>> I added support in the latest trunk to set the variable<br>
>>>> execute_on_answer to an application of your choice<br>
>>>><br>
>>>> <action application="set" data="execute_on_answer=sched_hangup +20<br>
>>>> alloted_timeout"/><br>
>>>><br>
>>>> --<br>
>>>> Anthony Minessale II<br>
>>>><br>
>>>> FreeSWITCH <a href="http://www.freeswitch.org/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org/</a><br>
>>>> ClueCon <a href="http://www.cluecon.com/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.cluecon.com/</a><br>
>>>><br>
>>>> AIM: anthm<br>
</div></div>>>>> <a href="mailto:MSN%3Aanthony_minessale@hotmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MSN:anthony_minessale@hotmail.com</a><<a href="mailto:MSN%253Aanthony_minessale@hotmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MSN%3Aanthony_minessale@hotmail.com</a>><br>
>>>> GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">PAYPAL:anthony.minessale@gmail.com</a><<a href="mailto:PAYPAL%253Aanthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">PAYPAL%3Aanthony.minessale@gmail.com</a>><br>
<div>>>>> IRC: <a href="http://irc.freenode.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">irc.freenode.net</a> #freeswitch<br>
>>>><br>
>>>> FreeSWITCH Developer Conference<br>
</div>>>>> <a href="mailto:sip%3A888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">sip:888@conference.freeswitch.org</a><<a href="mailto:sip%253A888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">sip%3A888@conference.freeswitch.org</a>><br>
<div>>>>> <a href="http://iax:guest@conference.freeswitch.org/888" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">iax:guest@conference.freeswitch.org/888</a><br>
</div>>>>> <a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">googletalk:conf+888@conference.freeswitch.org</a><<a href="mailto:googletalk%253Aconf%252B888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">googletalk%3Aconf%2B888@conference.freeswitch.org</a>><br>
<div>>>>> pstn:213-799-1400<br>
>>>> _______________________________________________<br>
>>>> Freeswitch-users mailing list<br>
>>>> <a href="mailto:Freeswitch-users@lists.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Freeswitch-users@lists.freeswitch.org</a><br>
>>>> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
>>>> UNSUBSCRIBE:<br>
>>>> <a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
>>>> <a href="http://www.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org</a><br>
>>>><br>
>>>><br>
>>>><br>
>>> _______________________________________________<br>
>>> Freeswitch-users mailing list<br>
>>> <a href="mailto:Freeswitch-users@lists.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Freeswitch-users@lists.freeswitch.org</a><br>
>>> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
>>> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
>>> <a href="http://www.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org</a><br>
>>><br>
>>><br>
>>><br>
>> --<br>
>> Anthony Minessale II<br>
>><br>
>> FreeSWITCH <a href="http://www.freeswitch.org/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org/</a><br>
>> ClueCon <a href="http://www.cluecon.com/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.cluecon.com/</a><br>
>><br>
>> AIM: anthm<br>
</div>>> <a href="mailto:MSN%3Aanthony_minessale@hotmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MSN:anthony_minessale@hotmail.com</a> <<a href="mailto:MSN%253Aanthony_minessale@hotmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MSN%3Aanthony_minessale@hotmail.com</a>><br>
>> GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">PAYPAL:anthony.minessale@gmail.com</a><<a href="mailto:PAYPAL%253Aanthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">PAYPAL%3Aanthony.minessale@gmail.com</a>><br>
<div>>> IRC: <a href="http://irc.freenode.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">irc.freenode.net</a> #freeswitch<br>
>><br>
>> FreeSWITCH Developer Conference<br>
</div>>> <a href="mailto:sip%3A888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">sip:888@conference.freeswitch.org</a> <<a href="mailto:sip%253A888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">sip%3A888@conference.freeswitch.org</a>><br>
<div>>> <a href="http://iax:guest@conference.freeswitch.org/888" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">iax:guest@conference.freeswitch.org/888</a><br>
</div>>> <a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">googletalk:conf+888@conference.freeswitch.org</a><<a href="mailto:googletalk%253Aconf%252B888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">googletalk%3Aconf%2B888@conference.freeswitch.org</a>><br>
<div><div></div><div>>> pstn:213-799-1400<br>
>><br>
>><br>
><br>
><br>
><br>
><br>
> ------------------------------------------------------------------------<br>
><br>
> _______________________________________________<br>
> Freeswitch-users mailing list<br>
> <a href="mailto:Freeswitch-users@lists.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Freeswitch-users@lists.freeswitch.org</a><br>
> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
> <a href="http://www.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org</a><br>
><br>
<br>
<br>
_______________________________________________<br>
Freeswitch-users mailing list<br>
<a href="mailto:Freeswitch-users@lists.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Freeswitch-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org</a><br>
</div></div></blockquote></div><br><br clear="all"><br></span></div>-- <br><span class="q">Anthony Minessale II<br><br>FreeSWITCH <a href="http://www.freeswitch.org/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.freeswitch.org/</a><br>
ClueCon <a href="http://www.cluecon.com/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.cluecon.com/</a><br>
<br>AIM: anthm<br><a href="mailto:MSN%3Aanthony_minessale@hotmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">MSN:anthony_minessale@hotmail.com</a><br></span><span class="q">GTALK/JABBER/<a href="mailto:PAYPAL%3Aanthony.minessale@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">PAYPAL:anthony.minessale@gmail.com</a><br>
</span><span class="q">
IRC: <a href="http://irc.freenode.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">irc.freenode.net</a> #freeswitch<br><br>FreeSWITCH Developer Conference<br><a href="mailto:sip%3A888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">sip:888@conference.freeswitch.org</a><br>
</span><span class="q"><a href="http://iax:guest@conference.freeswitch.org/888" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">iax:guest@conference.freeswitch.org/888</a><br>
<a href="mailto:googletalk%3Aconf%2B888@conference.freeswitch.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">googletalk:conf+888@conference.freeswitch.org</a><br></span>pstn:213-799-1400
<br>_______________________________________________<br>
Freeswitch-users mailing list<br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Freeswitch-users@lists.freeswitch.org">Freeswitch-users@lists.freeswitch.org</a><br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>