[OpenSIPS-Users] do_routing with failover to shorter prefix

Ben Newlin Ben.Newlin at genesys.com
Thu Jun 25 14:59:31 EST 2020

Yes, our configuration calls do_routing multiple times for different failover cases. You may want to verify this but I believe that the additional calls will append to the relevant AVPs used by the module, so if you haven’t routed to all destinations, you may need to clear out the AVPs prior to calling it again. I’m not positive on that part though; it may overwrite existing values.

We created a little helper route to do this:


Ben Newlin

From: Users <users-bounces at lists.opensips.org> on behalf of Vic Jolin <adjolin at gmail.com>
Reply-To: OpenSIPS users mailling list <users at lists.opensips.org>
Date: Thursday, June 25, 2020 at 10:49 AM
To: "users at lists.opensips.org" <users at lists.opensips.org>
Subject: [OpenSIPS-Users] do_routing with failover to shorter prefix


So I have this in my opensips.cfg

if ( !do_routing($(avp(drgID){s.int<http://s.int>}),,,,,$var(gw_attributes)) ) {
send_reply(404,"No Route found");

And I know that do_routing will match on the longer prefix on dr_rules table first.

My question is

Now after failing on all the routes, can we still do another do_routing with shorter prefix matching?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200625/5c1bd970/attachment-0001.html>

More information about the Users mailing list