[SR-Users] AVPs in timer-route

Klaus Darilion klaus.mailinglists at pernau.at
Wed Mar 21 18:05:19 CET 2012



On 20.03.2012 23:36, Daniel-Constantin Mierla wrote:
> Hello,
>
> On 3/20/12 8:13 PM, Klaus Darilion wrote:
>> Hi!
>>
>> I wonder what happens to AVPs defined in a route which is executed by
>> rtimer?
>>
>> It seems (tests on Kamailio 1.5) that the AVPs, once they are defined,
>> they life forever. This would be fine for my application.
>>
>> Are there any issues when using AVPs in timer routes?
> there is no issue using avps in rtimer routes. Those routes process a
> faked sip message, which does not change, just the internal id is
> increased. AVPs live for ever because they are cleaned up after a
> received messages is processed, but in this case there is no received
> context. It can be added to reset avps in rtimer module.
>
> On the other hand, avps are usually useful in context of a real sip
> message. Why you need them in a timer route?

I use rtimer module (backported from 1.5 to a quite extended openser 
1.3) to dump statistics in the timer route. The first time the timer 
route is executed I define some AVP-arrays (e.g. IP addresses of 
servers) over wich I loop in a while loop to dump the respective statistics.
regards
Klaus



More information about the sr-users mailing list