Skip to main content

Scheduling operations in EJB application

1 reply [Last post]
Mephysto
Offline
Joined: 2011-03-05
Points: 0

Hello to everyone,
I programming an EJB application with JDK 1.7.0_u4 and I use Glassfish Open Source 3.1.2 as application server. I need an object to do some operations at regular time intervals. Actually I use Timer and TimerTask java class to achieve my goal scheduling an endless timer.

My problem is that these timers remains alive when I unload my application and a new one start when I redeploy my application. The only way to stop all these timer is to restart Glassfish.

Is there a manner to destroy any live timers at application start? Is there another way to achieve my goal? Is there any other technology to do same thing?

I found EJB timers, but at the moment I have no idea about them behavior.

Can anyone help me?

Thanks in advance.

Reagards.

Mephysto

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
mngdiouf
Offline
Joined: 2010-02-04
Points: 0

Hi

Can you see quartz library

Cdt.