[SR-Users] Call Group versus MAX_BRANCHES limit

João Vitor Arruda joao.arruda at gmail.com
Mon Sep 29 22:47:28 CEST 2014


Hi folks,

I have a question related with the limited number of branches being 12 in
config.h
#define MAX_BRANCHES            12      /*!< maximum number of branches per
transaction */

I am trying to implement a Call Group that consists in trying each member
of the group (that can result in a parallel forking when lookup() is used)
in sequence (similar to serial forking).

Currently I have written code that is similar to the one described here:


http://www.kamailio.org/dokuwiki/dokuphp/tutorials:avpops#serial_forking

The only difference is that for each member I call lookup() and then in the
failure_route(), I pull the next member from the stack and call lookup()
again.  The code works fine when used for groups with less than 12
members.  However, call groups with 12 or more members fails as I can never
reach remaining extensions once MAX_BRANCHES limit is reached.

I've tried another approach using the functions described here:


http://kamailio.org/docs/modules/4.1.x/modules/tm.html#tm.serial_forking

but it too uses a new branch for every group member until the 12 limit is
reached out.

I also tried to use the functions "remove_branch(index)" and
"clear_branches()" (both of which are poorly documented.  In fact the only
reference I ever found for these functions was here:
http://www.kamailio.org/wiki/features/new-in-3.2.x#functions).
Unfortunately, I wasn't able to prevent the MAX_BRANCHES limit from being
reached.

Ultimately, my goal is to have a limitless Call Group.  Do you have any
suggestions? (other than increasing the hard coded MAX_BRANCHES limit)

Thank you,
Joao Arruda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20140929/045066a8/attachment.html>


More information about the sr-users mailing list