[SR-Users] Custom fr timer for dialog's OPTIONS keep alives

Alex Balashov abalashov at evaristesys.com
Thu Apr 17 13:39:45 CEST 2014


What are you going to do when this timer fires? 

Internally generated requests do not create TM transactions that are accessible from route script. 

What is your actual goal? To change the timeout for non-response to the OPTIONS keepalives? If so, that should probably be added as a modparam. In that case, fr_timer isn't quite the language in which to speak of it, as that makes it sound like a transaction to which you have access in script (with the implication that its failure can trigger a failure_route callback of your own making). That's not the case here. 


On 17 April 2014 15:33:57 GMT+04:00, Vassilis Radis <radisb at gmail.com> wrote:
>Hello, I would like to try customizing the fr_timer for the OPTIONS
>keep-alive msgs transactions that the dialog module sends. I tried to
>call
>t_set_fr() function from inside the dialog modules's code (in
>dlg_req_within.c , in dlg_send_ka() function after the call to d_tmb.
>t_request_within(&uac_r);
>But it seems that this tm function is not available from inside other
>module's code.
>
>Is the above is the correct place to try and do it, and how can I
>programmatically ,inside a module's code, adjust fr_timer?
>
>On a side note, i followed the call flow from dlg_send_ka() down to the
>t_uac_prepare() function of tm module, where the fr_timer is set. In
>there,
>there is this comment+code:
>
>/* init timers hack, new_cell->fr_timer and new_cell->fr_inv_timer
>	 * must be set, or else the fr will happen immediately
>	 * we can't call init_new_t() because we don't have a sip msg
>	 * => we'll ignore t_set_fr() or avp timer value and will use directly
>the
>	 * module params fr_inv_timer and fr_timer -- andrei */
>	new_cell->fr_timeout=cfg_get(tm, tm_cfg, fr_timeout);
>	new_cell->fr_inv_timeout=cfg_get(tm, tm_cfg, fr_inv_timeout);
>	new_cell->end_of_life=get_ticks_raw()+lifetime;
>
>Does this mean that it cant be done in a straighforward way?
>Any advice on how I can achieve the customized fr_timers for those
>messages?
>
>Thanks.
>
>
>------------------------------------------------------------------------
>
>_______________________________________________
>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>sr-users at lists.sip-router.org
>http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

--
Sent from my mobile, and thus lacking in the refinement one might expect from a fully fledged keyboard. 

Alex Balashov - Principal 
Evariste Systems LLC
235 E Ponce de Leon Ave
Suite 106
Decatur, GA 30030
United States
Tel: +1-678-954-0671
Web: http://www.evaristesys.com/, http://www.alexbalashov.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20140417/2f4f6914/attachment.html>


More information about the sr-users mailing list