Optimized method name camelCase

pull/656/head
chen.ma 2 years ago
parent b9247ef8d1
commit f936845d0e

@ -57,7 +57,7 @@ public class ThreadPoolRunStateHandler extends AbstractThreadPoolRuntime {
ByteConvertUtil.getPrintSize(runtimeInfo.getMaxMemory())).toString();
poolRunStateInfo.setCurrentLoad(poolRunStateInfo.getCurrentLoad() + "%");
poolRunStateInfo.setPeakLoad(poolRunStateInfo.getPeakLoad() + "%");
String ipAddress = hippo4JInetUtils.findFirstNonLoopbackHostInfo().getIpAddress();
String ipAddress = hippo4JInetUtils.findFirstNonLoopBackHostInfo().getIpAddress();
poolRunStateInfo.setHost(ipAddress);
poolRunStateInfo.setMemoryProportion(memoryProportion);
poolRunStateInfo.setFreeMemory(ByteConvertUtil.getPrintSize(runtimeInfo.getFreeMemory()));

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

@ -58,7 +58,7 @@ public class InetUtils implements Closeable {
this.executorService.shutdown();
}
public HostInfo findFirstNonLoopbackHostInfo() {
public HostInfo findFirstNonLoopBackHostInfo() {
InetAddress address = findFirstNonLoopbackAddress();
if (address != null) {
return convertAddress(address);

@ -55,9 +55,9 @@ public abstract class AbstractRefreshListener<M> implements RefreshListener<Hipp
AbstractRefreshListener() {
InetUtils inetUtils = ApplicationContextHolder.getBean(InetUtils.class);
InetUtils.HostInfo loopbackHostInfo = inetUtils.findFirstNonLoopbackHostInfo();
Assert.notNull(loopbackHostInfo, "Unable to get the application IP address");
ipSegment = loopbackHostInfo.getIpAddress().split(SPOT);
InetUtils.HostInfo loopBackHostInfo = inetUtils.findFirstNonLoopBackHostInfo();
Assert.notNull(loopBackHostInfo, "Unable to get the application IP address");
ipSegment = loopBackHostInfo.getIpAddress().split(SPOT);
}
@EventListener(WebServerInitializedEvent.class)

@ -29,7 +29,7 @@ public class CloudCommonIdUtil {
private static final String SEPARATOR = ":";
public static String getClientIpPort(PropertyResolver resolver, InetUtils inetUtils) {
String hostname = inetUtils.findFirstNonLoopbackHostInfo().getIpAddress();
String hostname = inetUtils.findFirstNonLoopBackHostInfo().getIpAddress();
String port = resolver.getProperty("server.port", "8080");
return combineParts(hostname, SEPARATOR, port);
}
@ -43,7 +43,7 @@ public class CloudCommonIdUtil {
@SneakyThrows
public static String getIpApplicationName(PropertyResolver resolver, InetUtils inetUtils) {
String hostname = inetUtils.findFirstNonLoopbackHostInfo().getIpAddress();
String hostname = inetUtils.findFirstNonLoopBackHostInfo().getIpAddress();
String appName = resolver.getProperty("spring.application.name");
return combineParts(hostname, SEPARATOR, appName);
}

Loading…
Cancel
Save