Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
izualzhy committed Nov 19, 2023
1 parent c97bc4f commit 3f8a97b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion quartz/src/main/java/cn/izualzhy/JobStartupRunner.java
Expand Up @@ -22,7 +22,7 @@ public class JobStartupRunner implements CommandLineRunner {
public void run(String... args) throws Exception {
try {
addJob(scheduler, 1, false);
addJob(scheduler, 2, false);
// addJob(scheduler, 2, false);
} catch (Exception e) {
System.out.println("e.message:" + e.getMessage());
}
Expand Down
2 changes: 1 addition & 1 deletion quartz/src/main/java/cn/izualzhy/QuartzJob.java
Expand Up @@ -24,7 +24,7 @@ protected void executeInternal(JobExecutionContext context) {
context.getScheduledFireTime());
try {
// 测试 misfire 时打开
// Thread.sleep(15000);
Thread.sleep(15000);
} catch (Exception e) {
}

Expand Down
4 changes: 2 additions & 2 deletions quartz/src/main/resources/application.yaml
Expand Up @@ -19,9 +19,9 @@ spring:
org.quartz.threadPool.class: org.quartz.simpl.SimpleThreadPool
org.quartz.jobStore.useProperties: false
org.quartz.threadPool.makeThreadsDaemons: true
org.quartz.threadPool.threadCount: 10
# org.quartz.threadPool.threadCount: 10
# 测试 misfire 时使用 1
# org.quartz.threadPool.threadCount: 1
org.quartz.threadPool.threadCount: 1
org.quartz.jobStore.misfireThreshold: 3000
org.quartz.scheduler.makeSchedulerThreadDaemon: true
org.quartz.jobStore.driverDelegateClass: org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
Expand Down

0 comments on commit 3f8a97b

Please sign in to comment.