[Freeswitch-users] Unexpected out of order command/reply '+OK event listener enabled plain' in perl ESL outbound

Dmitry Sytchev kbdfck at gmail.com
Wed Mar 16 19:28:47 MSK 2011


In my outbound async full ESL script after some moment there are
out-of-order message on every "execute" call, and this breaks my event
handling in some way.

Content-Type: command/reply.Reply-Text: +OK event listener enabled plain..
I want to execute some commands syncronously, but setEventLock seems to be
broken by this behavior.
As the workaround I had to write lock_for_execute_complete function, which
waits for execute completion of applications that need to be run sync, but
it effectively destroys async events by processing them while waiting for
CHANNEL_EXECUTE_COMPLETE.

here is a part of socket dump, note second "Content-Type:
command/reply.Reply-Text: +OK event listener enabled plain.." right after
execute. There is no event command in script besides the very beginning, so
why these messages appear?

T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
api uuid_setvar 06d55974-4fe8-11e0-a7c0-e3bb2141c22a
pbx_subscriber_customer_id 1
#
T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
..
##
T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
Content-Type: api/response.Content-Length: 4..
#
T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
+OK.
##
T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
  api sofia_contact s000002 at asdasd.com
#
T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
..
##
T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
Content-Type: api/response.Content-Length: 96..
#
T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
sofia/local/sip:s000002 at 172.19.36.54:5061;fs_nat=yes;fs_path=sip%3As000002%40172.19.36.54%3A5061

##
T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
Event-Name: SOCKET_DATA.Content-Type: api/response.Content-Length:
96..sofia/local/sip:s000002 at 172.19.36.54:5061;fs_nat=
yes;fs_path=sip%3As000002%40172.19.36.54%3A5061
#
T 127.0.0.1:8006 -> 127.0.0.1:43282 [AP]
sendmsg.call-command: execute.execute-app-name: bridge.execute-app-arg:
{originate_timeout=10,hangup_after_bridge=false,
  ignore_early_media=false}user/s000002 at asdasd.com
#
*T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
Content-Type: command/reply.Reply-Text: +OK event listener enabled plain.. *
#
T 127.0.0.1:43282 -> 127.0.0.1:8006 [AP]
Content-Type: command/reply.Reply-Text: +OK..

-- 
Best regards,

Dmitry Sytchev,
IT Engineer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20110316/a4f040ce/attachment.html 


More information about the FreeSWITCH-users mailing list