[SR-Users] Detecting end of DNS failover in tm:branch-failure

Ivan Ribakov i.ribakov at zaleos.net
Tue Feb 19 13:57:01 CET 2019


Hi all,

I have a custom routing logic implemented in my module. This routing logic may return a list of 2 or more endpoints where INVITE should be attempted to be routed. Since endpoint URI can contain domain names, I’m also trying to take care of DNS resolution. Based on the documentation found in https://github.com/kamailio/kamailio/blob/master/doc/tutorials/dns.txt <https://github.com/kamailio/kamailio/blob/master/doc/tutorials/dns.txt> current DNS resolver/failover logic takes good care of RFC3263.

To support switching between various endpoints returned by custom routing logic I have been using “tm:branch-failure” routing blocks. Problem I’m facing right now is that I am unable to distinguish between a DNS failover branch failure that has more SRV records to try and the “final” DNS failover branch failure (at which point I should be switching to another endpoint).

I’ve tried monitoring $T_reply_code values, but it is “408” in both cases.

Any ideas on how “final” and “non-final” DNS failover branch failures can be distinguished?

Regards,
Ivan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20190219/b221e457/attachment.html>


More information about the sr-users mailing list