Timer and TimerTask# Java - 爪哇娇娃
p*p
1 楼
There is lots of timer taskes in my software, such as session time out, auto-
reload and clean.... I use TimerTask.run and Timer.schedule(...) to implement
them.
In order to save rescoure, I use a single Timer for all such taskes in my
Application(somehow as a static). My question is, could it be a performance
hit when tousand such taskes running on single Timer, or i'd better use more
timers.
reload and clean.... I use TimerTask.run and Timer.schedule(...) to implement
them.
In order to save rescoure, I use a single Timer for all such taskes in my
Application(somehow as a static). My question is, could it be a performance
hit when tousand such taskes running on single Timer, or i'd better use more
timers.