File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Spring and the fly likes Programatically Creating Contriggerbean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "Programatically Creating Contriggerbean" Watch "Programatically Creating Contriggerbean" New topic

Programatically Creating Contriggerbean

p jayasankar

Joined: May 10, 2010
Posts: 2
I am new to Spring.

We have a requirement where we need to store scheduling related details in a database and at runtime we want to create CronTriggerBean by fetching data from database.

We have a table which contains following information
- Class name (which implement QuartzJobBean)
- cronExpression
When application starts, we want to fetch these information from database and create jobs based on database records. So that in future if we want to add new task, I can directly configure from database.

How to achieve this?
Mark Spritzler

Joined: Feb 05, 2001
Posts: 17276

Best way is to use Spring Batch. The documentation for Spring Batch is one of the best documentation out there. It uses a database to store jobs, as well as jobs that have run and their outcomes.


Perfect World Programming, LLC - iOS Apps
How to Ask Questions the Smart Way FAQ
I agree. Here's the link:
subject: Programatically Creating Contriggerbean
It's not a secret anymore!