mirror of
https://gitee.com/nutz/nutzboot.git
synced 2024-11-30 02:38:28 +08:00
- add: 增加Nacos配置项完整度判断,如果配置不完整,则跳过处理
This commit is contained in:
parent
212fb96dcd
commit
e9b8eecc76
@ -72,6 +72,9 @@ public class NacosConfigureStarter implements ServerFace {
|
||||
String group = conf.get(NACOS_GROUP);
|
||||
String dataType = conf.get(NACOS_DATA_TYPE);
|
||||
|
||||
if(Strings.isBlank(serverAddr) || Strings.isBlank(dataId) || Strings.isBlank(group) || Strings.isBlank(dataType)) {
|
||||
log.debugf("nacos server config is not found or incomplete, skip...");
|
||||
} else {
|
||||
Properties properties = new Properties();
|
||||
properties.put("serverAddr", serverAddr);
|
||||
ConfigService configService = NacosFactory.createConfigService(properties);
|
||||
@ -95,6 +98,7 @@ public class NacosConfigureStarter implements ServerFace {
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private void setConfig(String content, String contentType) {
|
||||
PropertiesProxy conf = appContext.getConf();
|
||||
|
Loading…
Reference in New Issue
Block a user