<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
<!--
@font-face
{font-family:"Cambria Math"}
@font-face
{font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman",serif}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline}
span.EmailStyle17
{font-family:"Calibri",sans-serif;
color:#1F497D}
span.EmailStyle18
{font-family:"Calibri",sans-serif;
color:#1F497D}
.MsoChpDefault
{font-size:10.0pt}
@page WordSection1
{margin:72.0pt 72.0pt 72.0pt 72.0pt}
div.WordSection1
{}
-->
</style>
</head>
<body lang="EN-GB" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">During testing I’ve come across another way for the limit to apply on B leg with-out transferring the call out of the LUA script.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">We simply execute this line before the bridge:</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">session:execute("export","nolocal:execute_on_pre_answer=limit hash "..domain_name.."_bleg "..extension.." "..limit_max.." "..limit_destination);</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">This results in the limit being applied on B leg before the call is answered.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">We continue to apply a separate limit on A leg as before, the above is be used as an additional measure to limit B leg in the event that extensions use features
such as attended transfer to exceed their available channels.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<div>
<div style="border:none; border-top:solid #E1E1E1 1.0pt; padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:11.0pt; font-family:"Calibri",sans-serif">From:</span></b><span lang="EN-US" style="font-size:11.0pt; font-family:"Calibri",sans-serif"> Shaun Stokes
<br>
<b>Sent:</b> 30 June 2017 16:23<br>
<b>To:</b> 'FreeSWITCH Users Help' <freeswitch-users@lists.freeswitch.org><br>
<b>Subject:</b> RE: [Freeswitch-users] Limit</span></p>
</div>
</div>
<p class="MsoNormal"> </p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">I should also point out, the extensions are transferring to external PSTN numbers not local to FreeSWITCH.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">I’ll give this a try and will provide feedback, we’ll need a new dialplan to bridge the gateway.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">Thanks,</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D">Shaun</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt; font-family:"Calibri",sans-serif; color:#1F497D"> </span></p>
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:11.0pt; font-family:"Calibri",sans-serif">From:</span></b><span lang="EN-US" style="font-size:11.0pt; font-family:"Calibri",sans-serif"> FreeSWITCH-users [<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org">mailto:freeswitch-users-bounces@lists.freeswitch.org</a>]
<b>On Behalf Of </b>Luis Daniel Lucio Quiroz<br>
<b>Sent:</b> 30 June 2017 12:45<br>
<b>To:</b> FreeSWITCH Users Help <<a href="mailto:freeswitch-users@lists.freeswitch.org">freeswitch-users@lists.freeswitch.org</a>><br>
<b>Subject:</b> Re: [Freeswitch-users] Limit</span></p>
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal">In your script, do a transfer instead a bridge. Let the dialplan deal with the bridge</p>
</div>
<div>
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal">Le 30 juin 2017 7:05 AM, "Shaun Stokes" <<a href="mailto:shaun.stokes@itec-support.co.uk">shaun.stokes@itec-support.co.uk</a>> a écrit :</p>
<blockquote style="border:none; border-left:solid #CCCCCC 1.0pt; padding:0cm 0cm 0cm 6.0pt; margin-left:4.8pt; margin-top:5.0pt; margin-right:0cm; margin-bottom:5.0pt">
<div>
<div>
<p class="MsoNormal" style="">Hi All,</p>
<p class="MsoNormal" style=""> </p>
<p class="MsoNormal" style="">In our environment we restrict the number of current channels (using limit) per extension, however using attended transfer allows extensions to exceed the limit since leg a ends once the transfer completes which resets the limit
to 0.</p>
<p class="MsoNormal" style=""> </p>
<p class="MsoNormal" style="">I believe the solution is to apply the limit on leg b, however leg b is initiated via a bridge (with-in our outbound LUA script).</p>
<p class="MsoNormal" style=""> </p>
<p class="MsoNormal" style="">How can we apply the limit to leg b, or is there a better solution?</p>
<p class="MsoNormal" style=""> </p>
<p class="MsoNormal" style="">Thanks,</p>
<p class="MsoNormal" style="">Shaun</p>
</div>
<table class="MsoNormalTable" border="0" cellspacing="3" cellpadding="0">
<tbody>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><img border="0" id="_x0000_i1025" src="http://www.itec-support.co.uk/wp-content/uploads/2016/07/email_logo.jpg"></p>
</td>
<td valign="top" style="padding:.75pt .75pt .75pt .75pt">
<div>
<p class="MsoNormal">Shaun Stokes - Infrastructure Analyst</p>
</div>
<div>
<table class="MsoNormalTable" border="0" cellspacing="3" cellpadding="0">
<tbody>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt"></td>
<td style="padding:.75pt .75pt .75pt .75pt"></td>
</tr>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal">T : </p>
</td>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal">01453 700713</p>
</td>
</tr>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal">E : </p>
</td>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><a href="mailto:shaun.stokes@itec-support.co.uk">shaun.stokes@itec-support.co.uk</a></p>
</td>
</tr>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal">W : </p>
</td>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><a href="http://www.itec-support.co.uk">www.itec-support.co.uk</a></p>
</td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
<div>
<p class="MsoNormal">Registered Address :- ITEC Support, Suite 2 Prospect House, Bath Road, Stroud, Gloucestershire GL5 3QF
<br>
Company No. 06908001 </p>
</div>
<div>
<p class="MsoNormal"><br>
CONFIDENTIALITY NOTICE <br>
This communication and the information it contains are intended for the person or organisation to which it is addressed. Its contents are confidential and may be protected in law. Unauthorised use, copying or disclosure of any of it may be unlawful. If you
are not the intended recipient, please contact us immediately. <br>
The contents of any attachments in this e-mail may contain software viruses, which could damage your own computer system. While ITEC Support has taken every reasonable precaution to minimise this risk, we cannot accept liability for any damage which you sustain
as a result of software viruses. You should carry out your own virus checking procedure before opening any attachment.
</p>
</div>
<p class="MsoNormal"><br>
______________________________________________________________________<br>
This message has been checked for all known viruses by MessageLabs Virus Scanning Service.<br>
______________________________________________________________________</p>
</div>
<p class="MsoNormal"><br>
_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a></p>
</blockquote>
</div>
</div>
<p class="MsoNormal"><br>
______________________________________________________________________<br>
This message has been checked for all known viruses by MessageLabs Virus Scanning Service.<br>
______________________________________________________________________</p>
</div>
<table>
<tbody>
<tr>
<td><img src="http://www.itec-support.co.uk/wp-content/uploads/2016/07/email_logo.jpg"></td>
<td valign="top">
<div><a style="font-family:calibri; color:#1B3E94; font-size:11pt">Shaun Stokes - Infrastructure Analyst</a></div>
<div>
<table>
<tbody>
<tr>
<td></td>
<td></td>
</tr>
<tr>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">T : </a></td>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">01453 700713</a></td>
</tr>
<tr>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">E : </a></td>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">shaun.stokes@itec-support.co.uk</a></td>
</tr>
<tr>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">W : </a></td>
<td><a style="font-family:calibri; color:#1B3E94; font-size:11pt">www.itec-support.co.uk</a></td>
</tr>
</tbody>
</table>
</div>
</td>
</tr>
</tbody>
</table>
<div><a style="font-family:calibri; color:#1B3E94; font-size:11pt">Registered Address :- ITEC Support, Suite 2 Prospect House, Bath Road, Stroud, Gloucestershire GL5 3QF</a>
<br>
<a style="font-family:calibri; color:#1B3E94; font-size:11pt">Company No. 06908001</a>
</div>
<div><br>
<a style="font-family:calibri; color:Grey; font-size:11pt">CONFIDENTIALITY NOTICE</a>
<br>
<a style="font-family:calibri; color:Grey; font-size:11pt">This communication and the information it contains are intended for the person or organisation to which it is addressed. Its contents are confidential and may be protected in law. Unauthorised use,
copying or disclosure of any of it may be unlawful. If you are not the intended recipient, please contact us immediately.</a>
<br>
<a style="font-family:calibri; color:Grey; font-size:11pt">The contents of any attachments in this e-mail may contain software viruses, which could damage your own computer system. While ITEC Support has taken every reasonable precaution to minimise this risk,
we cannot accept liability for any damage which you sustain as a result of software viruses. You should carry out your own virus checking procedure before opening any attachment.</a>
</div>
<br clear="both">
______________________________________________________________________<BR>
This message has been checked for all known viruses by MessageLabs Virus Scanning Service.<BR>
______________________________________________________________________<BR>
</body>
</html>