aspose file tools*
The moose likes Groovy and the fly likes Passing parameters to Quartz job Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Languages » Groovy
Bookmark "Passing parameters to Quartz job" Watch "Passing parameters to Quartz job" New topic
Author

Passing parameters to Quartz job

Pradeep bhatt
Ranch Hand

Joined: Feb 27, 2002
Posts: 8898

Does anyone know how to pass parameters to quartz job in grails and how to read those parameters in the job class.


Groovy
Peter Ledbrook
author
Greenhorn

Joined: Jul 15, 2009
Posts: 25
It depends what sort of parameters you are talking about. You can have any Spring-managed object (such as a Grails service) automatically injected into your job:



You can also access configuration data like so:



The config property on the application object gives you access to the data specified in grails-app/conf/Config.groovy.

Cheers,

Peter
Anton Vitrilo
Greenhorn

Joined: Nov 04, 2011
Posts: 1
The JobDetail object contains various property settings for the Job, as well as a JobDataMap, which can be used to store state information for a given instance of your job class.

 
 
subject: Passing parameters to Quartz job
 
Similar Threads
Java quartz cron job
open source project with thread / concurrency ?
WA #1.....word association
org.springframework.batch.core.repository.JobExecutionAlreadyRunningException
Jax-ws Oneway WebService not behaving as expected