Hi!

I have a Kamailio 1.5.2 handling 3XX messages. The commands below
are executed in a failure route. If the first contact is not reachable or
even a negative answer is received, the algorithm will call a second failure 
route, executing the 't_next_contacts'. Following this logic, the server will
try several endpoints. The first 200 OK received from one this endpoints
will establish the call. If all the contacts are tried, the server will 
finish the session with sending an error to the source. 

get_redirects("15:15","Redirect");
if(!t_load_contacts())
{
     t_reply("500", "Server Internal Error - Cannot load contacts");
     exit;
};
if(!t_next_contacts())
     t_reply("404", "Not found");
else
     t_relay();

Ok... I found just one problem. If the 3XX message brings 5 different contacts,
(all them with different q value), Kamailio just try 4 of them. 

Contact: sip:20182#556250982...@aaa.aaa.aaa.aaa;q=0.015,
sip:3441#556250982...@bbb.bbb.bbb.bbb;q=0.014,
sip:3441#556250982...@ccc.ccc.ccc.ccc;q=0.013,
sip:50014#556250982...@ddd.ddd.ddd.ddd;q=0.012,
sip:777#556250982...@eee.eee.eee.eee;q=0.011

After the 300 message, the server sends a invite to the first contact.
Seconds later, analysing the debug screen, I see:

DBG:tm:t_next_contacts: next contact is <sip:3441#556250982...@bbb.bbb.bbb.bbb

The INVITEs are sent to this IP. After some seconds the server calls the third 
contact:

DBG:tm:t_next_contacts: next contact is <sip:3441#556250982...@ccc.ccc.ccc.ccc

And so on until this, the last contact:

DBG:tm:t_next_contacts: next contact is <sip:777#556250982...@eee.eee.eee.eee
ERROR:core:add_avp: 0 ID or NULL NAME AVP
ERROR:tm:t_next_contacts: setting of fr_inv_timer_avp failed

The proxy sent INVITEs for all them, except the last one because this failure. 
The function 
't_next_contact' returns an error value. Somebody has a hint about this? 

Regards,
bruno machado



      
____________________________________________________________________________________
Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com
_______________________________________________
Kamailio (OpenSER) - Users mailing list
Users@lists.kamailio.org
http://lists.kamailio.org/cgi-bin/mailman/listinfo/users
http://lists.openser-project.org/cgi-bin/mailman/listinfo/users

Reply via email to