Hello,
I was comparing modules_s/timer with modules_k/rtimer to spot the
differences.
modules_s/timer is working only with core timers (fast and slow timers),
while the modules_k/rtimer can start own timer processes, or register a
task to main core timer.
Other differences ...
modules_s/timer:
- run on milisecond basis
- option to enable/disable timer
modules_k/rtimer
- run either on second or micro-second basis
- option to execute the many route blocks on same timer
So, apart of enable/disable timer option, rtimer can do more than what
timer module offer (mili-seconds can be run as 1000x micro-second).
Enabling/disabling a timer can be workarounded from script, using a
shared variable tested at begininning of rtimer route, like:
route[RTIMER] {
if($shv(rtimer)==0)
return;
...
}
Enabling will mean setting $shv(rtimer)=1, either from other parts of
the config or via MI/RPC commands.
Now, both modules can be kept, no naming conflict, it is just a matter
of code maintenance if we should keep timer module. Enabling/disabling
timers can be added to rtimer in the future, but it is unlikely to
happen before next major release (unless someone else does it).
Is anyone here using modules_s/timer module aware of other differences
comparing with rtimer?
Looking for comments to keep or obsolete modules_s/timer module ...
Cheers,
Daniel
--
Daniel-Constantin Mierla -
http://www.asipto.com
http://twitter.com/#!/miconda -
http://www.linkedin.com/in/miconda