users@glassfish.java.net

Re: EJB3 Timers

From: <glassfish_at_javadesktop.org>
Date: Wed, 16 May 2007 09:17:58 PDT

1) For SLSBs and MDBs, each EJB timer is associated with the bean(not the bean instance) that created it. The timer is persistent for the length of time that the application is deployed, even if
the server is stopped/restarted. The timers are stored in a database by the EJB container.

2) Each bean class can only have one @Timeout method. All timers created for that bean
will call that method when they expire. The createTimer "info" object is the best way to pass
information that is neeed when handling each timeout, since there is no guarantee that the
same bean instance that created the timer will be used for the call to @Timeout.

3) Right, see 1). Cancelling one timer doesn't affect any other timers. If you're seeing that
behavior please file a bug with a reproducible test case.
[Message sent by forum member 'ksak' (ksak)]

http://forums.java.net/jive/thread.jspa?messageID=217410