What is the internal mechanism for persisting data using Quartz Scheduler? I went through internet but didn't find clear description. It would be great if you suggest the same to work in hibernate platform.
When you use Quartz Scheduler in your project you should have a file for its properties which is called quartz.properties
. In this file you should determine your persistence mechanism by using parameter: org.quartz.jobStore.class
The value for this parameter can be the followings:
org.quartz.impl.jdbcjobstore.JobStoreCMT
: it means that you want to persist in a database and transactions are managed by a container (Like Weblogic, JBoss, ...)org.quartz.impl.jdbcjobstore.JobStoreTX
: it means that you want to persist in a database and transactions are NOT managed by a container. this option is used mostly when you run Quartz Scheduler as a standing alone application.org.quartz.simpl.RAMJobStore
: This option actually is not recommended in production environment because according this parameter Quartz persists jobs and triggers just in RAM!org.terracotta.quartz.TerracottaJobStore
: The last option is using Terracotta Server as your persistence unit, Quartz says that it is the fastest way.I myself prefer first option, it is straightforward and more reliable I think. You can read more about this configuration here. And about hibernate, quartz will manage the persistence tasks, like rollback and persist, and you wont being involved in this process.