I am forking a call to multiple destinations and want to keep the only branch which sends quicker provisional 180/183 reply and cancel the remaining branches. Below is my related cfg snippet.

modparam("tm", "failure_reply_mode", 3)
modparam("tm", "fr_timer", 30000)
modparam("tm", "fr_inv_timer", 120000)
modparam("tm", "cancel_b_method", 2)
...
route[SIPOUT] {
if (uri==myself) return;

    append_hf("P-hint: outbound\r\n");
    append_branch();
    append_branch();
    route(RELAY);
    exit;

}
onreply_route[MANAGE_REPLY] {
xdbg("incoming reply\n");
if(status="[12][0-9][0-9]") {
xlog("L_INFO","Received $rs (IP:$si:$sp)\n");
if(status=
"18[03]"){
t_cancel_branches("others");
xlog("L_INFO","cancelled all other branches\n");
}
route(NATMANAGE);
}
}
...

But I see kamailio does not instantly send CANCEL to other branches after it has received 180/180 from any branch.
Kamailio is sending CANCEL to other branches after they start sending 180/183 one by one.
I want to cancel other brances instantly as soon as i get reply from any other branch.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.