[SR-Users] Request timout - Change value
Daniel-Constantin Mierla
miconda at gmail.com
Mon Aug 24 12:40:14 CEST 2015
Hello,
there are parameters for tm module to set the timeout values: fr_timer
and fr_inv_timer.
When you want to set it per transaction with t_set_fr(), the best is to
do it somewhere before t_relay(), with the value you want for that
forwarding step.
Cheers,
Daniel
On 24/08/15 12:34, Loic Chabert wrote:
> Hello Daniel,
>
> Thanks for your reply, but i dont need to set timeout value for a
> particular request, i need to set it globally.
> Is-it possible to handle it ?
> If not, i will execute this function before launch t_on_failure().
>
> Thanks.
>
> 2015-08-24 12:23 GMT+02:00 Daniel-Constantin Mierla <miconda at gmail.com
> <mailto:miconda at gmail.com>>:
>
> Hello,
>
> see t_set_fr() function of tm module -- with it you can set the
> timeout per transaction, for each step of forwarding -- just use
> it when you want to change the value.
>
> Cheers,
> Daniel
>
>
> On 24/08/15 11:54, Loic Chabert wrote:
>> Hello everybody,
>>
>> I'm using kamailio as a dispatcher in front of asterisk boxes and
>> i use a failure route if asterisk box does not respond or send
>> 500error.
>>
>> failure_route[RTF_DISPATCH]{
>> if(t_is_canceled()){
>> exit();
>> }
>>
>> if(t_check_status("500") || (t_branch_timeout() &&
>> !t_branch_replied())){
>> xlog("L_WARN","[$fU@$si:$sp]{$rm} Asterisk Box $du is down\n");
>> ds_mark_dst("ip");
>> if(ds_next_dst()){
>> xlog("L_WARN","[$fU@$si:$sp]{$rm} Sending to Asterisk Box -
>> $du\n");
>> t_on_failure("RTF_DISPATCH");
>> route(RELAY);
>> exit;
>> }
>> }
>> }
>>
>> As you can see, i check if "t_branch_timeout() &&
>> !t_branch_replied()", but where has been stored timeout value ?
>> How can i change it ? For exemple, i need to set 1s, and then,
>> request expired.
>>
>> Thanks,
>> Regards.
>>
>>
>> _______________________________________________
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users at lists.sip-router.org <mailto:sr-users at lists.sip-router.org>
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
> --
> Daniel-Constantin Mierla
> http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> - http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.com
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing
> list
> sr-users at lists.sip-router.org <mailto:sr-users at lists.sip-router.org>
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
--
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Book: SIP Routing With Kamailio - http://www.asipto.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20150824/08df8678/attachment.html>
More information about the sr-users
mailing list