users@glassfish.java.net

Questions about JEE Timers

From: <forums_at_java.net>
Date: Fri, 26 Aug 2011 05:39:29 -0500 (CDT)

Hi,

I'm using GlassFish 3.1.1 so JEE6, I have some questions about the Timer
functionality.

If I create a timer using:

timerService.createSingleActionTimer(maxTimeout, timerConfig);

and this timer hits its timeout, is it removed from the system? I mean, will
it not be in the list I get from: timerService.getTimers(); ?

The second question:

timer.cancel(); throws the exception javax.ejb.NoSuchObjectLocalException
when does this happen?

It is in the case when the timer hits its timeout between getting it from the
list and calling cancel?

3. Is there a way to "reschedule" a timer? Say, you want to extend the
timeout? Other than cancel + new...

Thats it, thanks in advance!

Regards


--
[Message sent by forum member 'MohamzJava']
View Post: http://forums.java.net/node/837509