[Freeswitch-users] keep limit counter active across dialplans when used in attended transfers

Bipin Patel bipin at xbipin.com
Tue Jun 27 07:10:47 UTC 2017


hi,

and also hangup_after_bridge doesnt work to delete the key, need to use 
set_zombie_exec


Regards,
Bipin


------------------------------------------------------------------------
-------- Original Message --------
Subject: Re: [Freeswitch-users] keep limit counter active across 
dialplans when used in attended transfers
From: Bipin Patel <bipin at xbipin.com>
To: FreeSWITCH Users Help <freeswitch-users at lists.freeswitch.org>
Date: 6/27/2017, 11:06:03 AM
> hi,
>
> yes i was trying that but the problem occurs when ur doing attended 
> transfer because there when we set the hash key to oncall in the 
> features dialplan, the bridge is actually a att_xfer so it doesnt run 
> the delete command after C is hungup
>
>
> Regards,
> Bipin
>
>
> ------------------------------------------------------------------------
> -------- Original Message --------
> Subject: Re: [Freeswitch-users] keep limit counter active across 
> dialplans when used in attended transfers
> From: Vallimamod Abdullah <vma at vallimamod.org>
> To: FreeSWITCH Users Help <freeswitch-users at lists.freeswitch.org>
> Date: 6/27/2017, 10:58:13 AM
>> Hi,
>>
>> You can set hangup_after_bridge to false and delete the key after the 
>> bridge command.
>>
>> Best Regards,
>> -- 
>> Vallimamod Abdullah
>> SIP Solutions
>> Consulting VOIP
>> vma at sipsolutions.fr <mailto:vma at sipsolutions.fr>
>> .
>>
>>> On 26 Jun 2017, at 15:59, Bipin Patel <bipin at xbipin.com 
>>> <mailto:bipin at xbipin.com>> wrote:
>>>
>>> hi,
>>>
>>> i was testing mod_hash but how do we delete the key when the caller 
>>> has hung up causing originator cancel because the dialplan doesnt 
>>> execute any further, it does when the call is answered then hungup.
>>>
>>> Im assuming mod_hash works across dialplans because i didnt find 
>>> anything in docs that would suggest it wont
>>>
>>>
>>> Regards,
>>> Bipin
>>>
>>>
>>> ------------------------------------------------------------------------
>>> -------- Original Message --------
>>> Subject: Re: [Freeswitch-users] keep limit counter active across 
>>> dialplans when used in attended transfers
>>> From: Bipin Patel<bipin at xbipin.com>
>>> To: FreeSWITCH Users Help<freeswitch-users at lists.freeswitch.org>
>>> Date: 6/25/2017, 11:54:16 PM
>>>>
>>>> Hi,
>>>>
>>>> Well I could use it but with limit the counter decrementing etc is 
>>>> automatic so it's much simpler and reduces the dialplan required.
>>>>
>>>> In the dialplan I provided how do you think I could use it directly 
>>>> without adding any more extensions in the two dialplan, any help 
>>>> would be appreciated. What I need to do is increment counter for 
>>>> caller and callee as well as callee transferred to and check that 
>>>> counter before bridging so change ring back can be called.
>>>>
>>>> On June 25, 2017 8:43:29 PM Vallimamod 
>>>> Abdullah<vma at vallimamod.org>wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Is there any reason why you don't use the hash application 
>>>>> directly instead of limit?
>>>>> IMHO it is more suited to your use case.
>>>>>
>>>>> https://freeswitch.org/confluence/display/FREESWITCH/mod_hash
>>>>>
>>>>> Best Regards,
>>>>> -- 
>>>>> Vallimamod Abdullah
>>>>> SIP Solutions
>>>>> vma at sipsolutions.fr <mailto:vma at sipsolutions.fr>
>>>>> .
>>>>>
>>>>>
>>>>>> On 25 Jun 2017, at 17:10, Bipin Patel <bipin at xbipin.com 
>>>>>> <mailto:bipin at xbipin.com>> wrote:
>>>>>>
>>>>>> hi,
>>>>>>
>>>>>> i have a requirement where i need to generate a different 
>>>>>> ringtone if that ext is on another call and i do it using limit 
>>>>>> by setting a counter for the caller and callee and then checking 
>>>>>> the counter if it has a value of 1 which would mean that ext is 
>>>>>> on anohter call so generate a different ringtone and this work fine.
>>>>>>
>>>>>> The problem being if A calls B and B attended transfers the call 
>>>>>> to C then the counter for C is incremented in the features 
>>>>>> dialplan but it doesnt reflect in the internal dialplan and i 
>>>>>> read that active limits dont remain global across dialplans so is 
>>>>>> there anyway to keep the limit counter active. i tried 
>>>>>> limit_ignore_transfer but that doesnt seem to work, im on the FS 
>>>>>> master
>>>>>>
>>>>>> Below is my internal and features dialplan, any pointers would be 
>>>>>> helpful
>>>>>>
>>>>>>
>>>>>> INTERNAL DIALPLAN
>>>>>>
>>>>>> <extension name="general_stuff1" continue="true">
>>>>>> <condition>
>>>>>> <action application="set" data="rtp_negotiate_near_match=true"/>
>>>>>> <action application="set" data="inherit_codec=true"/>
>>>>>> <action application="set" data="suppress_cng=true"/>
>>>>>> <action application="set" data="limit_ignore_transfer=true" />
>>>>>> <action application="limit" data="hash max_calls ${sip_from_user} 
>>>>>> -1" />
>>>>>> </condition>
>>>>>> </extension>
>>>>>>
>>>>>> <extension name="ChangeRingBack">
>>>>>> <condition field="destination_number" expression="^ChangeRingBack$"/>
>>>>>> <condition field="rdnis" expression="^(.*$)">
>>>>>> <action application="set" 
>>>>>> data="transfer_ringback=%(250,250,400);%(250,3500,400)"/>
>>>>>> <action application="set" 
>>>>>> data="ringback=%(250,250,400);%(250,3500,400)"/>
>>>>>> <action application="bridge" data="sofia/internal/$1%$${domain}"/>
>>>>>> </condition>
>>>>>> </extension>
>>>>>>
>>>>>> <extension name="local_user_calling">
>>>>>> <condition field="destination_number" expression="^(.*)$">
>>>>>> <action application="limit" data="hash max_calls 
>>>>>> ${destination_number} -1" />
>>>>>> <action application="bind_meta_app" data="3 b s 
>>>>>> execute_extension::att_xfer XML features"/>
>>>>>> <action application="set" 
>>>>>> data="transfer_ringback=%(400,200,400,375);%(400,2000,400,375)"/>
>>>>>> <action application="set" data="hold_music=$${hold_music}" />
>>>>>> <action application="set" 
>>>>>> data="ringback=%(400,200,400,375);%(400,2000,400,375)"/>
>>>>>> <action application="set" data="call_timeout=30"/>
>>>>>> <action application="set" data="hangup_after_bridge=true"/>
>>>>>> <action application="set" data="continue_on_fail=true"/>
>>>>>> <action application="limit" data="hash max_calls 
>>>>>> ${destination_number} 1 ChangeRingBack"/>
>>>>>> <action application="bridge" data="sofia/internal/$1%$${domain}"/>
>>>>>> </condition>
>>>>>> </extension>
>>>>>>
>>>>>> FEATURES DIALPLAN
>>>>>>
>>>>>> <extension name="att_xfer">
>>>>>> <condition field="destination_number" expression="^att_xfer$">
>>>>>> <action application="set" 
>>>>>> data="transfer_ringback=%(400,200,400,375);%(400,2000,400,375)"/>
>>>>>> <action application="set" data="hold_music=$${hold_music}" />
>>>>>> <action application="set" 
>>>>>> data="ringback=%(400,200,400,375);%(400,2000,400,375)"/>
>>>>>> <action application="set" data="continue_on_fail=true"/>
>>>>>> <action application="read" data="2 11 ivr/ivr-enter_ext.wav 
>>>>>> digits 30000 #"/>
>>>>>> <action application="set" data="origination_cancel_key=#"/>
>>>>>> <action application="limit" data="hash max_calls ${digits} -1" />
>>>>>> <action application="att_xfer" 
>>>>>> data="sofia/internal/${digits}%$${domain}"/>
>>>>>> </condition>
>>>>>> </extension>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Regards,
>>>>>> Bipin
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------
>>>>>> _________________________________________________________________________
>>>>>> Professional FreeSWITCH Consulting Services:
>>>>>> consulting at freeswitch.org <mailto:consulting at freeswitch.org>
>>>>>> http://www.freeswitchsolutions.com 
>>>>>> <http://www.freeswitchsolutions.com/>
>>>>>>
>>>>>> Official FreeSWITCH Sites
>>>>>> http://www.freeswitch.org <http://www.freeswitch.org/>
>>>>>> http://confluence.freeswitch.org <http://confluence.freeswitch.org/>
>>>>>> http://www.cluecon.com <http://www.cluecon.com/>
>>>>>>
>>>>>> 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/>
>>>>>
>>>>> _________________________________________________________________________
>>>>> Professional FreeSWITCH Consulting Services:
>>>>> consulting at freeswitch.org <mailto:consulting%40freeswitch.org>
>>>>> http://www.freeswitchsolutions.com 
>>>>> <http://www.freeswitchsolutions.com/>
>>>>>
>>>>> Official FreeSWITCH Sites
>>>>> http://www.freeswitch.org <http://www.freeswitch.org/>
>>>>> http://confluence.freeswitch.org <http://confluence.freeswitch.org/>
>>>>> http://www.cluecon.com <http://www.cluecon.com/>
>>>>>
>>>>> FreeSWITCH-users mailing list
>>>>> FreeSWITCH-users at lists.freeswitch.org 
>>>>> <mailto:FreeSWITCH-users%40lists.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/>
>>>>
>>>>
>>>> _________________________________________________________________________
>>>> Professional FreeSWITCH Consulting Services:
>>>> consulting at freeswitch.org
>>>> http://www.freeswitchsolutions.com
>>>>
>>>> Official FreeSWITCH Sites
>>>> http://www.freeswitch.org
>>>> http://confluence.freeswitch.org
>>>> http://www.cluecon.com
>>>>
>>>> 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
>>>
>>> _________________________________________________________________________
>>> Professional FreeSWITCH Consulting Services:
>>> consulting at freeswitch.org <mailto:consulting at freeswitch.org>
>>> http://www.freeswitchsolutions.com <http://www.freeswitchsolutions.com/>
>>>
>>> Official FreeSWITCH Sites
>>> http://www.freeswitch.org <http://www.freeswitch.org/>
>>> http://confluence.freeswitch.org <http://confluence.freeswitch.org/>
>>> http://www.cluecon.com <http://www.cluecon.com/>
>>>
>>> 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/>
>>
>>
>>
>> _________________________________________________________________________
>> Professional FreeSWITCH Consulting Services:
>> consulting at freeswitch.org
>> http://www.freeswitchsolutions.com
>>
>> Official FreeSWITCH Sites
>> http://www.freeswitch.org
>> http://confluence.freeswitch.org
>> http://www.cluecon.com
>>
>> 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/20170627/2a7f0388/attachment-0001.html>


More information about the FreeSWITCH-users mailing list