opt:修正定时任务配置未生效问题
This commit is contained in:
@@ -18,7 +18,6 @@ import java.util.Properties;
|
|||||||
* @date 2019-01-07
|
* @date 2019-01-07
|
||||||
*/
|
*/
|
||||||
@Configuration
|
@Configuration
|
||||||
@ConditionalOnProperty(name = "autojob", havingValue = "true")
|
|
||||||
public class QuartzConfig {
|
public class QuartzConfig {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ import static org.quartz.TriggerBuilder.newTrigger;
|
|||||||
public class QuartzManage {
|
public class QuartzManage {
|
||||||
private static final String JOB_NAME = "TASK_";
|
private static final String JOB_NAME = "TASK_";
|
||||||
|
|
||||||
@Resource(name = "quartzScheduler")
|
@Resource(name = "scheduler")
|
||||||
private Scheduler scheduler;
|
private Scheduler scheduler;
|
||||||
|
|
||||||
public void addJob(SysQuartzJob quartzJob) {
|
public void addJob(SysQuartzJob quartzJob) {
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ spring:
|
|||||||
threadPool:
|
threadPool:
|
||||||
threadCount: 14
|
threadCount: 14
|
||||||
# class: org.nl.system.service.quartz.SimpleThreadPool
|
# class: org.nl.system.service.quartz.SimpleThreadPool
|
||||||
scheduler-name: quartzScheduler
|
scheduler-name: scheduler
|
||||||
task:
|
task:
|
||||||
pool:
|
pool:
|
||||||
# 核心线程池大小
|
# 核心线程池大小
|
||||||
|
|||||||
Reference in New Issue
Block a user