[jboss-user] [Advanced Documentation] - Re: need help with scheduler

PeterJ do-not-reply at jboss.com
Mon Dec 17 11:58:43 EST 2007

Try this. As an example, to schedule each Monday at noon:

Set initialStartDate to "12/17/2007 12:00" (use a valid date string for your locale)

Set schedulePeriod to 1 week (in milliseconds, of course)

That should work if you start the server today (at least in my time zone). But if you restart the server in a week or two, I don't know if it will automatically adjust the start time based on the period, I could not tell from a casual reading of the source code. My suggestion is to try it with an old date, maybe adding some logging statements to the code, and see what happens in that case. After all, you have the full source code for the scheduler class. And if it doesn't work right. you can always change the code.

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

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

More information about the jboss-user mailing list