This commit is contained in:
redkale
2023-12-18 17:07:16 +08:00
parent eb7c44de18
commit 7e45b458e9
3 changed files with 3 additions and 3 deletions

View File

@@ -44,7 +44,7 @@ public class CacheModuleEngine extends ModuleEngine {
public void onAppPostInit() {
//设置缓存管理器
this.cacheManager = CacheManagerService.create(null).enabled(false);
final AnyValue cacheConf = environment.getAnyValue("redkale.cache", false);
final AnyValue cacheConf = application.getAppConfig().getAnyValue("cache");;
this.resourceFactory.inject(this.cacheManager);
if (!application.isCompileMode() && cacheConf != null) {
this.cacheManager.init(cacheConf);

View File

@@ -143,7 +143,7 @@ public class ClusterModuleEngine extends ModuleEngine {
//第三方服务注册配置项的变更
if (!clusterChangedProps.isEmpty() || !clusterRemovedKeys.isEmpty()) {
if (this.clusterAgent != null) {
final AnyValueWriter old = (AnyValueWriter) environment.getAnyValue("redkale.cluster", false);
final AnyValueWriter old = (AnyValueWriter) application.getAppConfig().getAnyValue("cluster");
Properties newProps = new Properties();
newProps.putAll(clusterProperties);
List<ResourceEvent> changeEvents = new ArrayList<>();

View File

@@ -45,7 +45,7 @@ public class ScheduleModuleEngine extends ModuleEngine {
public void onAppPostInit() {
//设置定时管理器
this.scheduleManager = ScheduleManagerService.create(null).enabled(false);
final AnyValue scheduleConf = environment.getAnyValue("redkale.schedule", true);
final AnyValue scheduleConf = application.getAppConfig().getAnyValue("schedule", true);
this.resourceFactory.inject(this.scheduleManager);
if (!application.isCompileMode()) {
this.scheduleManager.init(scheduleConf);