Was planning to move from setting up cron jobs to Quartz scheduler. What are the pros/cons of using Quartz rather than setting up cron ?
Got this Time triggered job Cron or Quartz? link. Any other pointers ?
Cron allows you to create your own chains manually. Scheduler allows you to place resource control (CPU limits, undo tablespace limits, etc) against your job. It allows you to define classes with priorities and assign jobs to those classes.
The component uses either a CronTrigger or a SimpleTrigger . If no cron expression is provided, the component uses a simple trigger. If no groupName is provided, the quartz component uses the Camel group name.
Quartz can be used to create simple or complex schedules for executing tens, hundreds, or even tens-of-thousands of jobs; jobs whose tasks are defined as standard Java components that may execute virtually anything you may program them to do.
*/5 * * * * Execute a cron job every 5 minutes. 0 * * * * Execute a cron job every hour.
I have used and like quartz. Here are some advantages of quartz
Probably quartz should be seen more as a replacement for launching new threads than as a replacement of cron.
partially stolen from here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With