Hi Marcus.

They say that JBoss persists the timers to a database so that, if the server 
crashes, they will be restored at the next startup. This is true only if the 
server crashes, but not for a normal shutdown. 
My feeling is that they delete all timers that are not related to entity beans 
(ie. the field InstancePK in TIMERS table is NULL). In my case, I'm using only 
stateless session beans, so...

Two possible workarounds for persisting your timers in the case of a normal 
shutdown would be:

1. To modify yourself the JBoss'es source code, but you have to be careful not 
to break something in it.

2. To create a table (besides TIMERS) that will keep the necessary information 
to re-create the timers each time the server starts. For example, you can keep 
there the start date, interval, next run date, and at the startup (or at least 
when you'd want to create the timers) you can re-compute the next run and 
create a new timer.
I have opted for the second one and it works fine for me.
By the way, I'm using JBoss 4.0.1sp1 (JBoss 4.0.2RC1 presents the same 
situation).

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3873083#3873083

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3873083


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
JBoss-Development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to