Commit 6a85315d authored by 陈立彬's avatar 陈立彬

调度任务改为10秒一次

parent ece79536
...@@ -27,7 +27,7 @@ public class QuartzCronConfig { ...@@ -27,7 +27,7 @@ public class QuartzCronConfig {
public Trigger cronTrigger(JobDetail jobDetail) { public Trigger cronTrigger(JobDetail jobDetail) {
CronTriggerFactoryBean factoryBean = new CronTriggerFactoryBean(); CronTriggerFactoryBean factoryBean = new CronTriggerFactoryBean();
factoryBean.setJobDetail(jobDetail); factoryBean.setJobDetail(jobDetail);
factoryBean.setCronExpression("0 0/1 * * * ?"); // 每5分钟执行一次 factoryBean.setCronExpression("*/10 * * * * ?"); // 每5分钟执行一次
factoryBean.setName("cronTrigger"); factoryBean.setName("cronTrigger");
factoryBean.afterPropertiesSet(); factoryBean.afterPropertiesSet();
return factoryBean.getObject(); return factoryBean.getObject();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment