<div dir="ltr"><div>Anyone with mod_lua knowledge around here ?<br><br></div>Thanks,<br>Costin<br></div><div class="gmail_extra"><br><div class="gmail_quote">2015-02-11 11:57 GMT+02:00 CT Radu <span dir="ltr"><<a href="mailto:ct.radu.001@gmail.com" target="_blank">ct.radu.001@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi all,<br><br></div>I have the following problem:<br></div><div>I have an dialplan rule in freeswitch that delegates the control for the incoming call on a specific number to an erlang application.<br></div><div>This erlang application, at one point executes a lua script using the call:<br></div><div>{api, luarun, "luascript.lua uuid"}<br><br></div><div>In lua I do the following:<br></div><div>api = freeswitch.API();<br></div><div>session = freeswitch.session(argv[1]);<br><br></div><div>uuid = session:get_uuid();<br><br>if session:ready() then<br> uuid_break_cmd = "uuid_break ".. uuid .. " all";<br> uuid_hold_cmd = "uuid_hold off" .. uuid;<br> freeswitch.consoleLog("notice","uuid break cmd: ".. uuid_break_cmd .. "\n");<br> session:execute("break","all");<br> api:executeString(uuid_break_cmd);<br> reply = api:executeString(uuid_break_cmd);<br><br> freeswitch.consoleLog("notice", "After uuid_break.\n");<br>end<br><br></div><div>The thing is that freeswitch ignores completly uuid_break and uuid_hold off<br></div><div>The same command issued via fs_cli has effect.<br><br></div><div>In fs_cli on debug I can see this:<br>2015-02-10 20:23:51.405153 [NOTICE] switch_cpp.cpp:1328 uuid break cmd: uuid_break f36d5e5c-b151-11e4-9674-8f19f7458942 all<br>EXECUTE sofia/<a href="http://ctradu-dev.ezuce.ro/1002@ctradu-dev.ezuce.ro" target="_blank">ctradu-dev.ezuce.ro/1002@ctradu-dev.ezuce.ro</a> break(all)<br>2015-02-10 20:23:51.405153 [DEBUG] mod_erlang_event.c:169 Ignoring event CHANNEL_EXECUTE for attached session f36d5e5c-b151-11e4-9674-8f19f7458942<br>2015-02-10 20:23:51.405153 [DEBUG] mod_erlang_event.c:169 Ignoring event CHANNEL_EXECUTE_COMPLETE for attached session f36d5e5c-b151-11e4-9674-8f19f7458942<br>2015-02-10 20:23:51.405153 [NOTICE] switch_cpp.cpp:1328 After uuid_break.<br><br></div><div>Does anyone know why uuid_break has no effect executed from a script launched via api luarun ?<br></div><div>(And the same command when issued via fs_cli has effect)<br><br></div><div>The freeswitch version is 1.4.15~64bit<br><br></div><div>Thank you,<br>Costin<br></div><div><br></div><div><br><br></div></div>
</blockquote></div><br></div>