<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Let's work on a description on the logic needed and see if Vitally's code is close:<div><br></div><div>1. Connection dies (tcp, tls, sctp)</div><div>2. Event-route activates</div><div>3. Check if there's a outbound flow with reg-id associated with the flow</div><div>4. If not, is there a registration associated with the flow</div><div>5. If 3 or 4 is true, do something</div><div><br></div><div>Do we have functions for 3 and 4? Can this be done in scripting?</div><div><br></div><div>/O</div><div><br></div><div><br></div><div><br><div><div>27 aug 2013 kl. 09:18 skrev Peter Dunkley <<a href="mailto:peter.dunkley@crocodilertc.net">peter.dunkley@crocodilertc.net</a>>:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div dir="ltr">I started to implement this.  It is in a branch somewhere, but I couldn't get it working.<div><br></div><div>If someone who knows the TCP code better could take a look...</div><div><br></div><div>Regards,</div>
<div><br></div><div>Peter</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On 26 August 2013 23:28, Olle E. Johansson <span dir="ltr"><<a href="mailto:oej@edvina.net" target="_blank">oej@edvina.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
27 aug 2013 kl. 08:27 skrev "Olle E. Johansson" <<a href="mailto:oej@edvina.net">oej@edvina.net</a>>:<br>
<br>
><br>
> 27 aug 2013 kl. 00:29 skrev Vitaliy Aleksandrov <<a href="mailto:vitalik.voip@gmail.com">vitalik.voip@gmail.com</a>>:<br>
><br>
>> Hello,<br>
>><br>
>> I've made a patch to kamailio-4.0.3 which removes stale registration when kamailio looses an incoming tcp connection.<br>
>> Of course this patch needs more work.<br>
>><br>
>> Since the are no direct references between user location contacts and tcp connections callback function uses linear search through the whole location table using received field as a key.<br>
>><br>
>> Can anybody more experienced in kamailio internals check if I chose the right place to get information about lost tcp connections ?<br>
>> Another thing I wanted to ask is maybe somebody can suggest a better way to tie a tcp connection to the user location information without complicating "usrloc" module by any heavy data structures.<br>
>><br>
>> If anybody else except me need this It would be great to fix known problems and add it to kamailio.<br>
>> <remove_tcp_contacts.patch>_______________________________________________<br>
><br>
> This is something required for outbound too. We need to remove the registration and thus the flow if a connection dies. The problem is that we can manage the connection on another server (edge proxy) too.<br>
<br>
...which is why I earlier proposed an event-route for this use-case.<br>
<br>
/O<br>
_______________________________________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><div><font face="courier new, monospace">Peter Dunkley</font></div><div><font face="courier new, monospace">Technical Director</font></div><div>
<font face="courier new, monospace">Crocodile RCS Ltd</font></div></div>
</div>
_______________________________________________<br>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br><a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><br>http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users<br></blockquote></div><br></div></body></html>