Merge pull request #105 from voilaf/develop

配置文件未设置server.port时,DiscoveryConfiguration默认选择8080端口
pull/110/head
龙台 Long Tai 3 years ago committed by GitHub
commit b19c0a0d87
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -39,7 +39,7 @@ public class DiscoveryConfiguration {
public InstanceInfo instanceConfig() {
String namespace = properties.getNamespace();
String itemId = properties.getItemId();
String port = environment.getProperty("server.port");
String port = environment.getProperty("server.port", "8080");
String applicationName = environment.getProperty("spring.dynamic.thread-pool.item-id");
String active = environment.getProperty("spring.profiles.active", "UNKNOWN");

@ -37,7 +37,7 @@ public class IdentifyUtil {
return identify;
}
String ip = hippo4JInetUtils.findFirstNonLoopbackHostInfo().getIpAddress();
String port = environment.getProperty("server.port");
String port = environment.getProperty("server.port", "8080");
String identification = StrUtil.builder(ip,
":",
port,

Loading…
Cancel
Save