[Freeswitch-users] Check for freeswitch session exists

Peter Olsson peter.olsson at visionutveckling.se
Mon Mar 12 10:59:20 MSK 2012


Since ESL is event driven, there is no way to be 100% sure of this. However, the hangup event won't be missed, I guess it will just show up a little bit later (if you continue to read a few more events). So you will just have to handle the "errors" if you try to playback when the channel is hung up already, and then when you receive the hangup event, you know for sure that the call has ended.

/Peter


Från: freeswitch-users-bounces at lists.freeswitch.org [mailto:freeswitch-users-bounces at lists.freeswitch.org] För piyush singhai
Skickat: den 12 mars 2012 08:41
Till: FreeSWITCH Users Help
Ämne: [Freeswitch-users] Check for freeswitch session exists

Hello,

I am using ESL lib for making connection with freeswitch from the Application. Some time we miss the hangup event in application and instead make another execute request on the same session, lets say for playback(). Then we receive CHANNEL_EXECUTE_COMPLETE for application 'park' instead of playback(). Is this an indication that the session has already ended (in this case due to hangup by the user)? Otherwise how can we check before executing any new function that the session is still alive at fresswitch through ESL?


--Piyush





!DSPAM:4f5da6e632765021882877!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120312/76fb6031/attachment.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list