Are there clean ways to do these Quartz Triggers?

Posted by Ryan Elkins on Stack Overflow See other posts from Stack Overflow or by Ryan Elkins
Published on 2010-03-11T17:03:42Z Indexed on 2010/03/15 14:59 UTC
Read the original article Hit count: 364

I'm using Quartz to schedule some jobs but I have a few scenarios that I'm not sure how to resolve.

1) Lets say I have a job that is scheduled to run every 5 minutes. Generally that works well but periodically the job takes more than 5 minutes and I don't really want multiple instances of the job running simultaneously.

2) I have a job that can take between 1 and 60 minutes to complete. I want it to run continuously but pause for 10 minutes between runs, regardless of how long it took previously. I like using Quartz for this rather than some sort of loop because if a job crashes Quartz will still spin up a new one based on the schedule.

I am using Quartz in Java right now.

© Stack Overflow or respective owner

Related posts about quartz

Related posts about quartz-triggers