[Freeswitch-users] Lua script hangup detect

Nazim Agabekov nazim.agabekov at gmail.com
Wed Feb 10 23:45:02 PST 2010


Thanks Mike! Mod_Lua is great. I had experience with a lot of
proprietary IVR systems in the past.
FreeSWITCH and Mod_lua + luasql beats them all. Functionality is really
impressive.

On 02/11/2010 09:21 AM, Michael Jerris wrote:
> lua runs until you finish your script.  You need to exit when you are
> supposed to.  We have session::ready() for you to test this.
>
> Mike
>
> On Feb 10, 2010, at 12:53 PM, Nazim Agabekov wrote:
>
>> I think it continues to run until it finishes. I'll check it tomorrow
>> on my test system.
>>
>> On 02/10/2010 09:32 PM, Nicolas Brenner wrote:
>>>
>>> On Wed, Feb 10, 2010 at 1:34 PM, Nazim Agabekov
>>> <nazim.agabekov at gmail.com <mailto:nazim.agabekov at gmail.com>> wrote:
>>>
>>>     Lua script is not terminating immediately on hangup.
>>>
>>>
>>>
>>> When does it terminate then? Will the script terminate when it
>>> finishes running or does it need some special instruction?
>>>
>>>  
>>>
>>>     This behavior allows user to finalize the script nicely (free
>>>     dynamically allocated resources, update logs, e.t.c)
>>>
>>>>     maybe it will stuck in a few situation before it reach to
>>>>     session:status check point.
>>>>
>>>>     like GetDigit or something else? (sorry, I dont have FS right
>>>>     now, need test it tomorrow)
>>>     I've never encountered such a problem. Usually GetDigit-like
>>>     functions have timeout parameter, so they don't block forever.
>>>     Just check the session status often and it will work like a charm ;
>>>
>>>
>>>
>>>     On 02/10/2010 08:00 PM, Chia-Yen Wu wrote:
>>>>     thx for reply, but shouldnt Lua script terminate when client
>>>>     hangs up?
>>>>
>>>>     maybe it will stuck in a few situation before it reach to
>>>>     session:status check point.
>>>>
>>>>     like GetDigit or something else? (sorry, I dont have FS right
>>>>     now, need test it tomorrow)
>>>>
>>>>     2010/2/10 Nazim Agabekov <nazim.agabekov at gmail.com
>>>>     <mailto:nazim.agabekov at gmail.com>>
>>>>
>>>>         Hello,
>>>>         Can you pastebin your script?
>>>>
>>>>         http://pastebin.freeswitch.org
>>>>         <http://pastebin.freeswitch.org/>
>>>>
>>>>
>>>>         On 02/10/2010 01:17 PM, Chia-Yen Wu wrote:
>>>>>         Hello, 
>>>>>         i tried to use Lua script to replace xml macro in dialplan,
>>>>>         but I found out that Lua wont terminate if client hangup,
>>>>>         ,so the session is still on but client is already hangup,
>>>>>         is there a way to avoid this ?
>>>>>
>>>>>
>>>>>         _______________________________________________
>>>>>         FreeSWITCH-users mailing list
>>>>>         FreeSWITCH-users at lists.freeswitch.org <mailto:FreeSWITCH-users at lists.freeswitch.org>
>>>>>         http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>>>         UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>>>         http://www.freeswitch.org <http://www.freeswitch.org/>
>>>>>           
>>>>
>>>>
>>>>         _______________________________________________
>>>>         FreeSWITCH-users mailing list
>>>>         FreeSWITCH-users at lists.freeswitch.org
>>>>         <mailto:FreeSWITCH-users at lists.freeswitch.org>
>>>>         http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>>         UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>>         http://www.freeswitch.org <http://www.freeswitch.org/>
>>>>
>>>>
>>>>
>>>>     _______________________________________________
>>>>     FreeSWITCH-users mailing list
>>>>     FreeSWITCH-users at lists.freeswitch.org <mailto:FreeSWITCH-users at lists.freeswitch.org>
>>>>     http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>>     UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>>     http://www.freeswitch.org <http://www.freeswitch.org/>
>>>>       
>>>
>>>
>>>     _______________________________________________
>>>     FreeSWITCH-users mailing list
>>>     FreeSWITCH-users at lists.freeswitch.org
>>>     <mailto:FreeSWITCH-users at lists.freeswitch.org>
>>>     http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>     UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>     http://www.freeswitch.org <http://www.freeswitch.org/>
>>>
>>>
>>>
>>> _______________________________________________
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>>>   
>>
>> _______________________________________________
>> FreeSWITCH-users mailing list
>> FreeSWITCH-users at lists.freeswitch.org
>> <mailto:FreeSWITCH-users at lists.freeswitch.org>
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
>
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>   

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20100211/32984796/attachment-0002.html 


More information about the FreeSWITCH-users mailing list