mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-08-23 02:24:37 +00:00
perf[module]: Scheduler启动注释
This commit is contained in:
@@ -80,8 +80,7 @@ public class SchedulerContext implements ApplicationListener<ApplicationContextE
|
||||
|
||||
logger.info("Scheduler shutdown gracefully.");
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public void onApplicationEvent(ApplicationContextEvent event) {
|
||||
if (event instanceof ContextRefreshedEvent) {
|
||||
@@ -89,7 +88,9 @@ public class SchedulerContext implements ApplicationListener<ApplicationContextE
|
||||
SchedulerContext.instance = this;
|
||||
instance.applicationContext = event.getApplicationContext();
|
||||
inject();
|
||||
// 启动位于SchedulerBus的static静态代码块中
|
||||
} else if (event instanceof ContextClosedEvent) {
|
||||
// 反射获取executor,关闭掉
|
||||
shutdown();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user