Reputation: 1115
I have looked up this question in many forums and the answers seem to apply only to EJB 3.1 with TimerConfig method.
Is there a similar way to create a nonpersistent timer for EJB 2?
Upvotes: 1
Views: 109
Reputation: 33936
If you mean an application server that supports the EJB 3.1 API with an ejb-jar.xml file that contains version="2.1"
, then use TimerConfig.setPersistent
as usual.
If you mean an application server that only supports the EJB 2 API, then no, there is no standard way to create a non-persistent timer. Instead, you will need to use a non-standard solution like CommonJ or WebSphere AsynchBeans.
Upvotes: 1