<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hello,<br>
<br>
do you execute dlg_manage() for BYE requests? Or, if you rely on the
parameters to route headers, look at the BYE and see if it is there.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
<div class="moz-cite-prefix">On 17/09/15 19:02, José Seabra wrote:<br>
</div>
<blockquote
cite="mid:CAEVZRWv2VtGJSk3MHB9ivEw7THNc3e3hjzw5rCtJH1Ns_Xb+zg@mail.gmail.com"
type="cite">
<div dir="ltr">Hi there,
<div><br>
</div>
<div>I'm using a dialog module in a small kamailio script that
only does routing based on prefix, and relay the invite from
one ipaddr to another ip addr (diferent interfaces) using $fs
variavel.</div>
<div><br>
</div>
<div>
<div>Now i was introducing the dialog module to limit the
number of concurrent calls, and i noticed that it only can
increasing the number of dialogs, and it isn't decreasing
when receives the "BYE", I also noticed that when kamailio
receives "BYE" the dialog event route for state "end" is
not executed.</div>
</div>
<div><br>
</div>
<div>To count the number of concurrent calls I'm using the
following logic in main route:</div>
<div><br>
</div>
<div>
<div>if (is_method("INVITE")) {</div>
<div> setflag(FLT_ACC); # do accounting</div>
<div> dlg_manage();</div>
<div>
if(get_profile_size("concurrentcalls","local","$avp(s:size)"))</div>
<div> {</div>
<div> if($avp(s:size) != $null)</div>
<div> {</div>
<div> xlog("L_INFO",
"Number of calls for this server : $avp(s:size) -
ID=$ci\n"); </div>
<div> if($avp(s:size)
>= 15000)</div>
<div> {</div>
<div>
xlog("L_INFO", "Concurrent_max calls exceeded $avp(s:size)
for caller '$fU' - R=$ru ID=$ci\n");</div>
<div>
sl_send_reply("503", "Channel limit exceeded\n");</div>
<div> exit;</div>
<div> }</div>
<div><br>
</div>
<div> }</div>
<div> }</div>
<div>
set_dlg_profile("concurrentcalls","local");</div>
<div> }</div>
</div>
<div><br>
</div>
<div><br>
</div>
<div>Please check out the attachment with logs.<br>
</div>
<div><br>
</div>
<div>Best Regards</div>
<div>-- <br>
</div>
<div>
<div class="gmail_signature">
<div>José Seabra</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla
<a class="moz-txt-link-freetext" href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a>
Book: SIP Routing With Kamailio - <a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
Kamailio Advanced Training, Sep 28-30, 2015, in Berlin - <a class="moz-txt-link-freetext" href="http://asipto.com/u/kat">http://asipto.com/u/kat</a></pre>
</body>
</html>