java - Deltaspike and Quartz: How to set cronExpressions from a config file -
i guess title quite self-explained. have job:
import org.apache.deltaspike.scheduler.api.scheduled; import org.quartz.job; @scheduled(cronexpression = "0 0/1 * * * ?") public class joba implements job { //job code }
harcoded run every minute. set cron expression outside, i.e. config file. i'm using deltaspike, can't find way achieve it. thinking of class jobdispatcher maybe, create job , set cron expression it, see no clue in deltaspike documentation
thanks in advance!
make cron expression private final static constant deriving value config file , use in annotation.
Comments
Post a Comment