Remove Lombok from spring-cloud-netflix-eureka-client module (#2131)
This commit is contained in:
committed by
Spencer Gibb
parent
1c30c24639
commit
aa2159b7e5
@@ -111,13 +111,6 @@
|
||||
<artifactId>ribbon-httpclient</artifactId>
|
||||
<optional>true</optional>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<!-- Only needed at compile time -->
|
||||
<scope>compile</scope>
|
||||
<optional>true</optional>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-security</artifactId>
|
||||
|
||||
@@ -18,12 +18,12 @@ package org.springframework.cloud.netflix.eureka;
|
||||
|
||||
import com.netflix.discovery.shared.transport.EurekaTransportConfig;
|
||||
|
||||
import lombok.Data;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* @author Spencer Gibb
|
||||
* @author Gregor Zurowski
|
||||
*/
|
||||
@Data
|
||||
public class CloudEurekaTransportConfig implements EurekaTransportConfig {
|
||||
|
||||
private int sessionedClientReconnectIntervalSeconds = 20 * 60;
|
||||
@@ -59,4 +59,153 @@ public class CloudEurekaTransportConfig implements EurekaTransportConfig {
|
||||
public boolean applicationsResolverUseIp() {
|
||||
return this.applicationsResolverUseIp;
|
||||
}
|
||||
|
||||
public int getSessionedClientReconnectIntervalSeconds() {
|
||||
return sessionedClientReconnectIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setSessionedClientReconnectIntervalSeconds(
|
||||
int sessionedClientReconnectIntervalSeconds) {
|
||||
this.sessionedClientReconnectIntervalSeconds = sessionedClientReconnectIntervalSeconds;
|
||||
}
|
||||
|
||||
public double getRetryableClientQuarantineRefreshPercentage() {
|
||||
return retryableClientQuarantineRefreshPercentage;
|
||||
}
|
||||
|
||||
public void setRetryableClientQuarantineRefreshPercentage(
|
||||
double retryableClientQuarantineRefreshPercentage) {
|
||||
this.retryableClientQuarantineRefreshPercentage = retryableClientQuarantineRefreshPercentage;
|
||||
}
|
||||
|
||||
public int getBootstrapResolverRefreshIntervalSeconds() {
|
||||
return bootstrapResolverRefreshIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setBootstrapResolverRefreshIntervalSeconds(
|
||||
int bootstrapResolverRefreshIntervalSeconds) {
|
||||
this.bootstrapResolverRefreshIntervalSeconds = bootstrapResolverRefreshIntervalSeconds;
|
||||
}
|
||||
|
||||
public int getApplicationsResolverDataStalenessThresholdSeconds() {
|
||||
return applicationsResolverDataStalenessThresholdSeconds;
|
||||
}
|
||||
|
||||
public void setApplicationsResolverDataStalenessThresholdSeconds(
|
||||
int applicationsResolverDataStalenessThresholdSeconds) {
|
||||
this.applicationsResolverDataStalenessThresholdSeconds = applicationsResolverDataStalenessThresholdSeconds;
|
||||
}
|
||||
|
||||
public int getAsyncResolverRefreshIntervalMs() {
|
||||
return asyncResolverRefreshIntervalMs;
|
||||
}
|
||||
|
||||
public void setAsyncResolverRefreshIntervalMs(int asyncResolverRefreshIntervalMs) {
|
||||
this.asyncResolverRefreshIntervalMs = asyncResolverRefreshIntervalMs;
|
||||
}
|
||||
|
||||
public int getAsyncResolverWarmUpTimeoutMs() {
|
||||
return asyncResolverWarmUpTimeoutMs;
|
||||
}
|
||||
|
||||
public void setAsyncResolverWarmUpTimeoutMs(int asyncResolverWarmUpTimeoutMs) {
|
||||
this.asyncResolverWarmUpTimeoutMs = asyncResolverWarmUpTimeoutMs;
|
||||
}
|
||||
|
||||
public int getAsyncExecutorThreadPoolSize() {
|
||||
return asyncExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
public void setAsyncExecutorThreadPoolSize(int asyncExecutorThreadPoolSize) {
|
||||
this.asyncExecutorThreadPoolSize = asyncExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
public String getReadClusterVip() {
|
||||
return readClusterVip;
|
||||
}
|
||||
|
||||
public void setReadClusterVip(String readClusterVip) {
|
||||
this.readClusterVip = readClusterVip;
|
||||
}
|
||||
|
||||
public String getWriteClusterVip() {
|
||||
return writeClusterVip;
|
||||
}
|
||||
|
||||
public void setWriteClusterVip(String writeClusterVip) {
|
||||
this.writeClusterVip = writeClusterVip;
|
||||
}
|
||||
|
||||
public boolean isBootstrapResolverForQuery() {
|
||||
return bootstrapResolverForQuery;
|
||||
}
|
||||
|
||||
public void setBootstrapResolverForQuery(boolean bootstrapResolverForQuery) {
|
||||
this.bootstrapResolverForQuery = bootstrapResolverForQuery;
|
||||
}
|
||||
|
||||
public String getBootstrapResolverStrategy() {
|
||||
return bootstrapResolverStrategy;
|
||||
}
|
||||
|
||||
public void setBootstrapResolverStrategy(String bootstrapResolverStrategy) {
|
||||
this.bootstrapResolverStrategy = bootstrapResolverStrategy;
|
||||
}
|
||||
|
||||
public boolean isApplicationsResolverUseIp() {
|
||||
return applicationsResolverUseIp;
|
||||
}
|
||||
|
||||
public void setApplicationsResolverUseIp(boolean applicationsResolverUseIp) {
|
||||
this.applicationsResolverUseIp = applicationsResolverUseIp;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
CloudEurekaTransportConfig that = (CloudEurekaTransportConfig) o;
|
||||
return sessionedClientReconnectIntervalSeconds == that.sessionedClientReconnectIntervalSeconds &&
|
||||
Double.compare(retryableClientQuarantineRefreshPercentage, that.retryableClientQuarantineRefreshPercentage) == 0 &&
|
||||
bootstrapResolverRefreshIntervalSeconds == that.bootstrapResolverRefreshIntervalSeconds &&
|
||||
applicationsResolverDataStalenessThresholdSeconds == that.applicationsResolverDataStalenessThresholdSeconds &&
|
||||
asyncResolverRefreshIntervalMs == that.asyncResolverRefreshIntervalMs &&
|
||||
asyncResolverWarmUpTimeoutMs == that.asyncResolverWarmUpTimeoutMs &&
|
||||
asyncExecutorThreadPoolSize == that.asyncExecutorThreadPoolSize &&
|
||||
Objects.equals(readClusterVip, that.readClusterVip) &&
|
||||
Objects.equals(writeClusterVip, that.writeClusterVip) &&
|
||||
bootstrapResolverForQuery == that.bootstrapResolverForQuery &&
|
||||
Objects.equals(bootstrapResolverStrategy, that.bootstrapResolverStrategy) &&
|
||||
applicationsResolverUseIp == that.applicationsResolverUseIp;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(sessionedClientReconnectIntervalSeconds,
|
||||
retryableClientQuarantineRefreshPercentage,
|
||||
bootstrapResolverRefreshIntervalSeconds,
|
||||
applicationsResolverDataStalenessThresholdSeconds,
|
||||
asyncResolverRefreshIntervalMs, asyncResolverWarmUpTimeoutMs,
|
||||
asyncExecutorThreadPoolSize, readClusterVip, writeClusterVip,
|
||||
bootstrapResolverForQuery, bootstrapResolverStrategy,
|
||||
applicationsResolverUseIp);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new StringBuilder("CloudEurekaTransportConfig{")
|
||||
.append("sessionedClientReconnectIntervalSeconds=").append(sessionedClientReconnectIntervalSeconds).append(", ")
|
||||
.append("retryableClientQuarantineRefreshPercentage=").append(retryableClientQuarantineRefreshPercentage).append(", ")
|
||||
.append("bootstrapResolverRefreshIntervalSeconds=").append(bootstrapResolverRefreshIntervalSeconds).append(", ")
|
||||
.append("applicationsResolverDataStalenessThresholdSeconds=").append(applicationsResolverDataStalenessThresholdSeconds).append(", ")
|
||||
.append("asyncResolverRefreshIntervalMs=").append(asyncResolverRefreshIntervalMs).append(", ")
|
||||
.append("asyncResolverWarmUpTimeoutMs=").append(asyncResolverWarmUpTimeoutMs).append(", ")
|
||||
.append("asyncExecutorThreadPoolSize=").append(asyncExecutorThreadPoolSize).append(", ")
|
||||
.append("readClusterVip='").append(readClusterVip).append("', ")
|
||||
.append("writeClusterVip='").append(writeClusterVip).append("', ")
|
||||
.append("bootstrapResolverForQuery=").append(bootstrapResolverForQuery).append(", ")
|
||||
.append("bootstrapResolverStrategy='").append(bootstrapResolverStrategy).append("', ")
|
||||
.append("applicationsResolverUseIp=").append(applicationsResolverUseIp).append(", ").append("}")
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
@@ -31,14 +32,12 @@ import com.netflix.appinfo.EurekaAccept;
|
||||
import com.netflix.discovery.EurekaClientConfig;
|
||||
import com.netflix.discovery.shared.transport.EurekaTransportConfig;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import static org.springframework.cloud.netflix.eureka.EurekaConstants.DEFAULT_PREFIX;
|
||||
|
||||
/**
|
||||
* @author Dave Syer
|
||||
* @author Gregor Zurowski
|
||||
*/
|
||||
@Data
|
||||
@ConfigurationProperties(EurekaClientConfigBean.PREFIX)
|
||||
public class EurekaClientConfigBean implements EurekaClientConfig {
|
||||
|
||||
@@ -486,4 +485,501 @@ public class EurekaClientConfigBean implements EurekaClientConfig {
|
||||
public EurekaTransportConfig getTransportConfig() {
|
||||
return getTransport();
|
||||
}
|
||||
|
||||
public PropertyResolver getPropertyResolver() {
|
||||
return propertyResolver;
|
||||
}
|
||||
|
||||
public void setPropertyResolver(PropertyResolver propertyResolver) {
|
||||
this.propertyResolver = propertyResolver;
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
return enabled;
|
||||
}
|
||||
|
||||
public void setEnabled(boolean enabled) {
|
||||
this.enabled = enabled;
|
||||
}
|
||||
|
||||
public EurekaTransportConfig getTransport() {
|
||||
return transport;
|
||||
}
|
||||
|
||||
public void setTransport(EurekaTransportConfig transport) {
|
||||
this.transport = transport;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getRegistryFetchIntervalSeconds() {
|
||||
return registryFetchIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setRegistryFetchIntervalSeconds(int registryFetchIntervalSeconds) {
|
||||
this.registryFetchIntervalSeconds = registryFetchIntervalSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getInstanceInfoReplicationIntervalSeconds() {
|
||||
return instanceInfoReplicationIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setInstanceInfoReplicationIntervalSeconds(
|
||||
int instanceInfoReplicationIntervalSeconds) {
|
||||
this.instanceInfoReplicationIntervalSeconds = instanceInfoReplicationIntervalSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getInitialInstanceInfoReplicationIntervalSeconds() {
|
||||
return initialInstanceInfoReplicationIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setInitialInstanceInfoReplicationIntervalSeconds(
|
||||
int initialInstanceInfoReplicationIntervalSeconds) {
|
||||
this.initialInstanceInfoReplicationIntervalSeconds = initialInstanceInfoReplicationIntervalSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaServiceUrlPollIntervalSeconds() {
|
||||
return eurekaServiceUrlPollIntervalSeconds;
|
||||
}
|
||||
|
||||
public void setEurekaServiceUrlPollIntervalSeconds(
|
||||
int eurekaServiceUrlPollIntervalSeconds) {
|
||||
this.eurekaServiceUrlPollIntervalSeconds = eurekaServiceUrlPollIntervalSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getProxyPort() {
|
||||
return proxyPort;
|
||||
}
|
||||
|
||||
public void setProxyPort(String proxyPort) {
|
||||
this.proxyPort = proxyPort;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getProxyHost() {
|
||||
return proxyHost;
|
||||
}
|
||||
|
||||
public void setProxyHost(String proxyHost) {
|
||||
this.proxyHost = proxyHost;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getProxyUserName() {
|
||||
return proxyUserName;
|
||||
}
|
||||
|
||||
public void setProxyUserName(String proxyUserName) {
|
||||
this.proxyUserName = proxyUserName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getProxyPassword() {
|
||||
return proxyPassword;
|
||||
}
|
||||
|
||||
public void setProxyPassword(String proxyPassword) {
|
||||
this.proxyPassword = proxyPassword;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaServerReadTimeoutSeconds() {
|
||||
return eurekaServerReadTimeoutSeconds;
|
||||
}
|
||||
|
||||
public void setEurekaServerReadTimeoutSeconds(int eurekaServerReadTimeoutSeconds) {
|
||||
this.eurekaServerReadTimeoutSeconds = eurekaServerReadTimeoutSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaServerConnectTimeoutSeconds() {
|
||||
return eurekaServerConnectTimeoutSeconds;
|
||||
}
|
||||
|
||||
public void setEurekaServerConnectTimeoutSeconds(
|
||||
int eurekaServerConnectTimeoutSeconds) {
|
||||
this.eurekaServerConnectTimeoutSeconds = eurekaServerConnectTimeoutSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBackupRegistryImpl() {
|
||||
return backupRegistryImpl;
|
||||
}
|
||||
|
||||
public void setBackupRegistryImpl(String backupRegistryImpl) {
|
||||
this.backupRegistryImpl = backupRegistryImpl;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaServerTotalConnections() {
|
||||
return eurekaServerTotalConnections;
|
||||
}
|
||||
|
||||
public void setEurekaServerTotalConnections(int eurekaServerTotalConnections) {
|
||||
this.eurekaServerTotalConnections = eurekaServerTotalConnections;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaServerTotalConnectionsPerHost() {
|
||||
return eurekaServerTotalConnectionsPerHost;
|
||||
}
|
||||
|
||||
public void setEurekaServerTotalConnectionsPerHost(
|
||||
int eurekaServerTotalConnectionsPerHost) {
|
||||
this.eurekaServerTotalConnectionsPerHost = eurekaServerTotalConnectionsPerHost;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEurekaServerURLContext() {
|
||||
return eurekaServerURLContext;
|
||||
}
|
||||
|
||||
public void setEurekaServerURLContext(String eurekaServerURLContext) {
|
||||
this.eurekaServerURLContext = eurekaServerURLContext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEurekaServerPort() {
|
||||
return eurekaServerPort;
|
||||
}
|
||||
|
||||
public void setEurekaServerPort(String eurekaServerPort) {
|
||||
this.eurekaServerPort = eurekaServerPort;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEurekaServerDNSName() {
|
||||
return eurekaServerDNSName;
|
||||
}
|
||||
|
||||
public void setEurekaServerDNSName(String eurekaServerDNSName) {
|
||||
this.eurekaServerDNSName = eurekaServerDNSName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRegion() {
|
||||
return region;
|
||||
}
|
||||
|
||||
public void setRegion(String region) {
|
||||
this.region = region;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEurekaConnectionIdleTimeoutSeconds() {
|
||||
return eurekaConnectionIdleTimeoutSeconds;
|
||||
}
|
||||
|
||||
public void setEurekaConnectionIdleTimeoutSeconds(
|
||||
int eurekaConnectionIdleTimeoutSeconds) {
|
||||
this.eurekaConnectionIdleTimeoutSeconds = eurekaConnectionIdleTimeoutSeconds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRegistryRefreshSingleVipAddress() {
|
||||
return registryRefreshSingleVipAddress;
|
||||
}
|
||||
|
||||
public void setRegistryRefreshSingleVipAddress(
|
||||
String registryRefreshSingleVipAddress) {
|
||||
this.registryRefreshSingleVipAddress = registryRefreshSingleVipAddress;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getHeartbeatExecutorThreadPoolSize() {
|
||||
return heartbeatExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
public void setHeartbeatExecutorThreadPoolSize(int heartbeatExecutorThreadPoolSize) {
|
||||
this.heartbeatExecutorThreadPoolSize = heartbeatExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getHeartbeatExecutorExponentialBackOffBound() {
|
||||
return heartbeatExecutorExponentialBackOffBound;
|
||||
}
|
||||
|
||||
public void setHeartbeatExecutorExponentialBackOffBound(
|
||||
int heartbeatExecutorExponentialBackOffBound) {
|
||||
this.heartbeatExecutorExponentialBackOffBound = heartbeatExecutorExponentialBackOffBound;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCacheRefreshExecutorThreadPoolSize() {
|
||||
return cacheRefreshExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
public void setCacheRefreshExecutorThreadPoolSize(
|
||||
int cacheRefreshExecutorThreadPoolSize) {
|
||||
this.cacheRefreshExecutorThreadPoolSize = cacheRefreshExecutorThreadPoolSize;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCacheRefreshExecutorExponentialBackOffBound() {
|
||||
return cacheRefreshExecutorExponentialBackOffBound;
|
||||
}
|
||||
|
||||
public void setCacheRefreshExecutorExponentialBackOffBound(
|
||||
int cacheRefreshExecutorExponentialBackOffBound) {
|
||||
this.cacheRefreshExecutorExponentialBackOffBound = cacheRefreshExecutorExponentialBackOffBound;
|
||||
}
|
||||
|
||||
public Map<String, String> getServiceUrl() {
|
||||
return serviceUrl;
|
||||
}
|
||||
|
||||
public void setServiceUrl(Map<String, String> serviceUrl) {
|
||||
this.serviceUrl = serviceUrl;
|
||||
}
|
||||
|
||||
public boolean isgZipContent() {
|
||||
return gZipContent;
|
||||
}
|
||||
|
||||
public void setgZipContent(boolean gZipContent) {
|
||||
this.gZipContent = gZipContent;
|
||||
}
|
||||
|
||||
public boolean isUseDnsForFetchingServiceUrls() {
|
||||
return useDnsForFetchingServiceUrls;
|
||||
}
|
||||
|
||||
public void setUseDnsForFetchingServiceUrls(boolean useDnsForFetchingServiceUrls) {
|
||||
this.useDnsForFetchingServiceUrls = useDnsForFetchingServiceUrls;
|
||||
}
|
||||
|
||||
public boolean isRegisterWithEureka() {
|
||||
return registerWithEureka;
|
||||
}
|
||||
|
||||
public void setRegisterWithEureka(boolean registerWithEureka) {
|
||||
this.registerWithEureka = registerWithEureka;
|
||||
}
|
||||
|
||||
public boolean isPreferSameZoneEureka() {
|
||||
return preferSameZoneEureka;
|
||||
}
|
||||
|
||||
public void setPreferSameZoneEureka(boolean preferSameZoneEureka) {
|
||||
this.preferSameZoneEureka = preferSameZoneEureka;
|
||||
}
|
||||
|
||||
public boolean isLogDeltaDiff() {
|
||||
return logDeltaDiff;
|
||||
}
|
||||
|
||||
public void setLogDeltaDiff(boolean logDeltaDiff) {
|
||||
this.logDeltaDiff = logDeltaDiff;
|
||||
}
|
||||
|
||||
public boolean isDisableDelta() {
|
||||
return disableDelta;
|
||||
}
|
||||
|
||||
public void setDisableDelta(boolean disableDelta) {
|
||||
this.disableDelta = disableDelta;
|
||||
}
|
||||
|
||||
public String getFetchRemoteRegionsRegistry() {
|
||||
return fetchRemoteRegionsRegistry;
|
||||
}
|
||||
|
||||
public void setFetchRemoteRegionsRegistry(String fetchRemoteRegionsRegistry) {
|
||||
this.fetchRemoteRegionsRegistry = fetchRemoteRegionsRegistry;
|
||||
}
|
||||
|
||||
public Map<String, String> getAvailabilityZones() {
|
||||
return availabilityZones;
|
||||
}
|
||||
|
||||
public void setAvailabilityZones(Map<String, String> availabilityZones) {
|
||||
this.availabilityZones = availabilityZones;
|
||||
}
|
||||
|
||||
public boolean isFilterOnlyUpInstances() {
|
||||
return filterOnlyUpInstances;
|
||||
}
|
||||
|
||||
public void setFilterOnlyUpInstances(boolean filterOnlyUpInstances) {
|
||||
this.filterOnlyUpInstances = filterOnlyUpInstances;
|
||||
}
|
||||
|
||||
public boolean isFetchRegistry() {
|
||||
return fetchRegistry;
|
||||
}
|
||||
|
||||
public void setFetchRegistry(boolean fetchRegistry) {
|
||||
this.fetchRegistry = fetchRegistry;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDollarReplacement() {
|
||||
return dollarReplacement;
|
||||
}
|
||||
|
||||
public void setDollarReplacement(String dollarReplacement) {
|
||||
this.dollarReplacement = dollarReplacement;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEscapeCharReplacement() {
|
||||
return escapeCharReplacement;
|
||||
}
|
||||
|
||||
public void setEscapeCharReplacement(String escapeCharReplacement) {
|
||||
this.escapeCharReplacement = escapeCharReplacement;
|
||||
}
|
||||
|
||||
public boolean isAllowRedirects() {
|
||||
return allowRedirects;
|
||||
}
|
||||
|
||||
public void setAllowRedirects(boolean allowRedirects) {
|
||||
this.allowRedirects = allowRedirects;
|
||||
}
|
||||
|
||||
public boolean isOnDemandUpdateStatusChange() {
|
||||
return onDemandUpdateStatusChange;
|
||||
}
|
||||
|
||||
public void setOnDemandUpdateStatusChange(boolean onDemandUpdateStatusChange) {
|
||||
this.onDemandUpdateStatusChange = onDemandUpdateStatusChange;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getEncoderName() {
|
||||
return encoderName;
|
||||
}
|
||||
|
||||
public void setEncoderName(String encoderName) {
|
||||
this.encoderName = encoderName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDecoderName() {
|
||||
return decoderName;
|
||||
}
|
||||
|
||||
public void setDecoderName(String decoderName) {
|
||||
this.decoderName = decoderName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getClientDataAccept() {
|
||||
return clientDataAccept;
|
||||
}
|
||||
|
||||
public void setClientDataAccept(String clientDataAccept) {
|
||||
this.clientDataAccept = clientDataAccept;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
EurekaClientConfigBean that = (EurekaClientConfigBean) o;
|
||||
return Objects.equals(propertyResolver, that.propertyResolver) &&
|
||||
enabled == that.enabled &&
|
||||
Objects.equals(transport, that.transport) &&
|
||||
registryFetchIntervalSeconds == that.registryFetchIntervalSeconds &&
|
||||
instanceInfoReplicationIntervalSeconds == that.instanceInfoReplicationIntervalSeconds &&
|
||||
initialInstanceInfoReplicationIntervalSeconds == that.initialInstanceInfoReplicationIntervalSeconds &&
|
||||
eurekaServiceUrlPollIntervalSeconds == that.eurekaServiceUrlPollIntervalSeconds &&
|
||||
eurekaServerReadTimeoutSeconds == that.eurekaServerReadTimeoutSeconds &&
|
||||
eurekaServerConnectTimeoutSeconds == that.eurekaServerConnectTimeoutSeconds &&
|
||||
eurekaServerTotalConnections == that.eurekaServerTotalConnections &&
|
||||
eurekaServerTotalConnectionsPerHost == that.eurekaServerTotalConnectionsPerHost &&
|
||||
eurekaConnectionIdleTimeoutSeconds == that.eurekaConnectionIdleTimeoutSeconds &&
|
||||
heartbeatExecutorThreadPoolSize == that.heartbeatExecutorThreadPoolSize &&
|
||||
heartbeatExecutorExponentialBackOffBound == that.heartbeatExecutorExponentialBackOffBound &&
|
||||
cacheRefreshExecutorThreadPoolSize == that.cacheRefreshExecutorThreadPoolSize &&
|
||||
cacheRefreshExecutorExponentialBackOffBound == that.cacheRefreshExecutorExponentialBackOffBound &&
|
||||
gZipContent == that.gZipContent &&
|
||||
useDnsForFetchingServiceUrls == that.useDnsForFetchingServiceUrls &&
|
||||
registerWithEureka == that.registerWithEureka &&
|
||||
preferSameZoneEureka == that.preferSameZoneEureka &&
|
||||
logDeltaDiff == that.logDeltaDiff &&
|
||||
disableDelta == that.disableDelta &&
|
||||
filterOnlyUpInstances == that.filterOnlyUpInstances &&
|
||||
fetchRegistry == that.fetchRegistry &&
|
||||
allowRedirects == that.allowRedirects &&
|
||||
onDemandUpdateStatusChange == that.onDemandUpdateStatusChange &&
|
||||
Objects.equals(proxyPort, that.proxyPort) &&
|
||||
Objects.equals(proxyHost, that.proxyHost) &&
|
||||
Objects.equals(proxyUserName, that.proxyUserName) &&
|
||||
Objects.equals(proxyPassword, that.proxyPassword) &&
|
||||
Objects.equals(backupRegistryImpl, that.backupRegistryImpl) &&
|
||||
Objects.equals(eurekaServerURLContext, that.eurekaServerURLContext) &&
|
||||
Objects.equals(eurekaServerPort, that.eurekaServerPort) &&
|
||||
Objects.equals(eurekaServerDNSName, that.eurekaServerDNSName) &&
|
||||
Objects.equals(region, that.region) &&
|
||||
Objects.equals(registryRefreshSingleVipAddress, that.registryRefreshSingleVipAddress) &&
|
||||
Objects.equals(serviceUrl, that.serviceUrl) &&
|
||||
Objects.equals(fetchRemoteRegionsRegistry, that.fetchRemoteRegionsRegistry) &&
|
||||
Objects.equals(availabilityZones, that.availabilityZones) &&
|
||||
Objects.equals(dollarReplacement, that.dollarReplacement) &&
|
||||
Objects.equals(escapeCharReplacement, that.escapeCharReplacement) &&
|
||||
Objects.equals(encoderName, that.encoderName) &&
|
||||
Objects.equals(decoderName, that.decoderName) &&
|
||||
Objects.equals(clientDataAccept, that.clientDataAccept);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new StringBuilder("EurekaClientConfigBean{")
|
||||
.append("propertyResolver=").append(propertyResolver).append(", ")
|
||||
.append("enabled=").append(enabled).append(", ")
|
||||
.append("transport=").append(transport).append(", ")
|
||||
.append("registryFetchIntervalSeconds=").append(registryFetchIntervalSeconds).append(", ")
|
||||
.append("instanceInfoReplicationIntervalSeconds=").append(instanceInfoReplicationIntervalSeconds).append(", ")
|
||||
.append("initialInstanceInfoReplicationIntervalSeconds=").append(initialInstanceInfoReplicationIntervalSeconds).append(", ")
|
||||
.append("eurekaServiceUrlPollIntervalSeconds=").append(eurekaServiceUrlPollIntervalSeconds).append(", ")
|
||||
.append("proxyPort='").append(proxyPort).append("', ")
|
||||
.append("proxyHost='").append(proxyHost).append("', ")
|
||||
.append("proxyUserName='").append(proxyUserName).append("', ")
|
||||
.append("proxyPassword='").append(proxyPassword).append("', ")
|
||||
.append("eurekaServerReadTimeoutSeconds=").append(eurekaServerReadTimeoutSeconds).append(", ")
|
||||
.append("eurekaServerConnectTimeoutSeconds=").append(eurekaServerConnectTimeoutSeconds).append(", ")
|
||||
.append("backupRegistryImpl='").append(backupRegistryImpl).append("', ")
|
||||
.append("eurekaServerTotalConnections=").append(eurekaServerTotalConnections).append(", ")
|
||||
.append("eurekaServerTotalConnectionsPerHost=").append(eurekaServerTotalConnectionsPerHost).append(", ")
|
||||
.append("eurekaServerURLContext='").append(eurekaServerURLContext).append("', ")
|
||||
.append("eurekaServerPort='").append(eurekaServerPort).append("', ")
|
||||
.append("eurekaServerDNSName='").append(eurekaServerDNSName).append("', ")
|
||||
.append("region='").append(region).append("', ")
|
||||
.append("eurekaConnectionIdleTimeoutSeconds=").append(eurekaConnectionIdleTimeoutSeconds).append(", ")
|
||||
.append("registryRefreshSingleVipAddress='").append(registryRefreshSingleVipAddress).append("', ")
|
||||
.append("heartbeatExecutorThreadPoolSize=").append(heartbeatExecutorThreadPoolSize).append(", ")
|
||||
.append("heartbeatExecutorExponentialBackOffBound=").append(heartbeatExecutorExponentialBackOffBound).append(", ")
|
||||
.append("cacheRefreshExecutorThreadPoolSize=").append(cacheRefreshExecutorThreadPoolSize).append(", ")
|
||||
.append("cacheRefreshExecutorExponentialBackOffBound=").append(cacheRefreshExecutorExponentialBackOffBound).append(", ")
|
||||
.append("serviceUrl=").append(serviceUrl).append(", ")
|
||||
.append("gZipContent=").append(gZipContent).append(", ")
|
||||
.append("useDnsForFetchingServiceUrls=").append(useDnsForFetchingServiceUrls).append(", ")
|
||||
.append("registerWithEureka=").append(registerWithEureka).append(", ")
|
||||
.append("preferSameZoneEureka=").append(preferSameZoneEureka).append(", ")
|
||||
.append("logDeltaDiff=").append(logDeltaDiff).append(", ")
|
||||
.append("disableDelta=").append(disableDelta).append(", ")
|
||||
.append("fetchRemoteRegionsRegistry='").append(fetchRemoteRegionsRegistry).append("', ")
|
||||
.append("availabilityZones=").append(availabilityZones).append(", ")
|
||||
.append("filterOnlyUpInstances=").append(filterOnlyUpInstances).append(", ")
|
||||
.append("fetchRegistry=").append(fetchRegistry).append(", ")
|
||||
.append("dollarReplacement='").append(dollarReplacement).append("', ")
|
||||
.append("escapeCharReplacement='").append(escapeCharReplacement).append("', ")
|
||||
.append("allowRedirects=").append(allowRedirects).append(", ")
|
||||
.append("onDemandUpdateStatusChange=").append(onDemandUpdateStatusChange).append(", ")
|
||||
.append("encoderName='").append(encoderName).append("', ")
|
||||
.append("decoderName='").append(decoderName).append("', ")
|
||||
.append("clientDataAccept='").append(clientDataAccept).append("'").append("}")
|
||||
.toString();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -35,12 +35,9 @@ import com.netflix.discovery.EurekaClient;
|
||||
import com.netflix.discovery.shared.Application;
|
||||
import com.netflix.discovery.shared.Applications;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author Spencer Gibb
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
public class EurekaDiscoveryClient implements DiscoveryClient {
|
||||
|
||||
public static final String DESCRIPTION = "Spring Cloud Eureka Discovery Client";
|
||||
@@ -49,6 +46,11 @@ public class EurekaDiscoveryClient implements DiscoveryClient {
|
||||
|
||||
private final EurekaClient eurekaClient;
|
||||
|
||||
public EurekaDiscoveryClient(EurekaInstanceConfig config, EurekaClient eurekaClient) {
|
||||
this.config = config;
|
||||
this.eurekaClient = eurekaClient;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String description() {
|
||||
return DESCRIPTION;
|
||||
|
||||
@@ -16,8 +16,10 @@
|
||||
|
||||
package org.springframework.cloud.netflix.eureka;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
|
||||
import org.springframework.boot.bind.RelaxedPropertyResolver;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
@@ -31,28 +33,19 @@ import com.netflix.appinfo.DataCenterInfo;
|
||||
import com.netflix.appinfo.InstanceInfo.InstanceStatus;
|
||||
import com.netflix.appinfo.MyDataCenterInfo;
|
||||
|
||||
import lombok.AccessLevel;
|
||||
import lombok.Data;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author Dave Syer
|
||||
* @author Spencer Gibb
|
||||
* @author Ryan Baxter
|
||||
* @author Gregor Zurowski
|
||||
*/
|
||||
@Data
|
||||
@ConfigurationProperties("eureka.instance")
|
||||
public class EurekaInstanceConfigBean implements CloudEurekaInstanceConfig, EnvironmentAware {
|
||||
|
||||
private static final String UNKNOWN = "unknown";
|
||||
|
||||
@Getter(AccessLevel.PRIVATE)
|
||||
@Setter(AccessLevel.PRIVATE)
|
||||
private HostInfo hostInfo;
|
||||
|
||||
@Getter(AccessLevel.PRIVATE)
|
||||
@Setter(AccessLevel.PRIVATE)
|
||||
private InetUtils inetUtils;
|
||||
|
||||
/**
|
||||
@@ -339,4 +332,321 @@ public class EurekaInstanceConfigBean implements CloudEurekaInstanceConfig, Envi
|
||||
setSecureVirtualHostName(springAppName);
|
||||
}
|
||||
}
|
||||
|
||||
private HostInfo getHostInfo() {
|
||||
return hostInfo;
|
||||
}
|
||||
|
||||
private void setHostInfo(HostInfo hostInfo) {
|
||||
this.hostInfo = hostInfo;
|
||||
}
|
||||
|
||||
private InetUtils getInetUtils() {
|
||||
return inetUtils;
|
||||
}
|
||||
|
||||
private void setInetUtils(InetUtils inetUtils) {
|
||||
this.inetUtils = inetUtils;
|
||||
}
|
||||
|
||||
public String getAppname() {
|
||||
return appname;
|
||||
}
|
||||
|
||||
public void setAppname(String appname) {
|
||||
this.appname = appname;
|
||||
}
|
||||
|
||||
public String getAppGroupName() {
|
||||
return appGroupName;
|
||||
}
|
||||
|
||||
public void setAppGroupName(String appGroupName) {
|
||||
this.appGroupName = appGroupName;
|
||||
}
|
||||
|
||||
public boolean isInstanceEnabledOnit() {
|
||||
return instanceEnabledOnit;
|
||||
}
|
||||
|
||||
public void setInstanceEnabledOnit(boolean instanceEnabledOnit) {
|
||||
this.instanceEnabledOnit = instanceEnabledOnit;
|
||||
}
|
||||
|
||||
public int getNonSecurePort() {
|
||||
return nonSecurePort;
|
||||
}
|
||||
|
||||
public void setNonSecurePort(int nonSecurePort) {
|
||||
this.nonSecurePort = nonSecurePort;
|
||||
}
|
||||
|
||||
public int getSecurePort() {
|
||||
return securePort;
|
||||
}
|
||||
|
||||
public void setSecurePort(int securePort) {
|
||||
this.securePort = securePort;
|
||||
}
|
||||
|
||||
public boolean isNonSecurePortEnabled() {
|
||||
return nonSecurePortEnabled;
|
||||
}
|
||||
|
||||
public void setNonSecurePortEnabled(boolean nonSecurePortEnabled) {
|
||||
this.nonSecurePortEnabled = nonSecurePortEnabled;
|
||||
}
|
||||
|
||||
public boolean isSecurePortEnabled() {
|
||||
return securePortEnabled;
|
||||
}
|
||||
|
||||
public void setSecurePortEnabled(boolean securePortEnabled) {
|
||||
this.securePortEnabled = securePortEnabled;
|
||||
}
|
||||
|
||||
public int getLeaseRenewalIntervalInSeconds() {
|
||||
return leaseRenewalIntervalInSeconds;
|
||||
}
|
||||
|
||||
public void setLeaseRenewalIntervalInSeconds(int leaseRenewalIntervalInSeconds) {
|
||||
this.leaseRenewalIntervalInSeconds = leaseRenewalIntervalInSeconds;
|
||||
}
|
||||
|
||||
public int getLeaseExpirationDurationInSeconds() {
|
||||
return leaseExpirationDurationInSeconds;
|
||||
}
|
||||
|
||||
public void setLeaseExpirationDurationInSeconds(
|
||||
int leaseExpirationDurationInSeconds) {
|
||||
this.leaseExpirationDurationInSeconds = leaseExpirationDurationInSeconds;
|
||||
}
|
||||
|
||||
public String getVirtualHostName() {
|
||||
return virtualHostName;
|
||||
}
|
||||
|
||||
public void setVirtualHostName(String virtualHostName) {
|
||||
this.virtualHostName = virtualHostName;
|
||||
}
|
||||
|
||||
public void setInstanceId(String instanceId) {
|
||||
this.instanceId = instanceId;
|
||||
}
|
||||
|
||||
public String getSecureVirtualHostName() {
|
||||
return secureVirtualHostName;
|
||||
}
|
||||
|
||||
public void setSecureVirtualHostName(String secureVirtualHostName) {
|
||||
this.secureVirtualHostName = secureVirtualHostName;
|
||||
}
|
||||
|
||||
public String getASGName() {
|
||||
return aSGName;
|
||||
}
|
||||
|
||||
public void setASGName(String aSGName) {
|
||||
this.aSGName = aSGName;
|
||||
}
|
||||
|
||||
public Map<String, String> getMetadataMap() {
|
||||
return metadataMap;
|
||||
}
|
||||
|
||||
public void setMetadataMap(Map<String, String> metadataMap) {
|
||||
this.metadataMap = metadataMap;
|
||||
}
|
||||
|
||||
public DataCenterInfo getDataCenterInfo() {
|
||||
return dataCenterInfo;
|
||||
}
|
||||
|
||||
public void setDataCenterInfo(DataCenterInfo dataCenterInfo) {
|
||||
this.dataCenterInfo = dataCenterInfo;
|
||||
}
|
||||
|
||||
public String getIpAddress() {
|
||||
return ipAddress;
|
||||
}
|
||||
|
||||
public String getStatusPageUrlPath() {
|
||||
return statusPageUrlPath;
|
||||
}
|
||||
|
||||
public void setStatusPageUrlPath(String statusPageUrlPath) {
|
||||
this.statusPageUrlPath = statusPageUrlPath;
|
||||
}
|
||||
|
||||
public String getStatusPageUrl() {
|
||||
return statusPageUrl;
|
||||
}
|
||||
|
||||
public void setStatusPageUrl(String statusPageUrl) {
|
||||
this.statusPageUrl = statusPageUrl;
|
||||
}
|
||||
|
||||
public String getHomePageUrlPath() {
|
||||
return homePageUrlPath;
|
||||
}
|
||||
|
||||
public void setHomePageUrlPath(String homePageUrlPath) {
|
||||
this.homePageUrlPath = homePageUrlPath;
|
||||
}
|
||||
|
||||
public String getHomePageUrl() {
|
||||
return homePageUrl;
|
||||
}
|
||||
|
||||
public void setHomePageUrl(String homePageUrl) {
|
||||
this.homePageUrl = homePageUrl;
|
||||
}
|
||||
|
||||
public String getHealthCheckUrlPath() {
|
||||
return healthCheckUrlPath;
|
||||
}
|
||||
|
||||
public void setHealthCheckUrlPath(String healthCheckUrlPath) {
|
||||
this.healthCheckUrlPath = healthCheckUrlPath;
|
||||
}
|
||||
|
||||
public String getHealthCheckUrl() {
|
||||
return healthCheckUrl;
|
||||
}
|
||||
|
||||
public void setHealthCheckUrl(String healthCheckUrl) {
|
||||
this.healthCheckUrl = healthCheckUrl;
|
||||
}
|
||||
|
||||
public String getSecureHealthCheckUrl() {
|
||||
return secureHealthCheckUrl;
|
||||
}
|
||||
|
||||
public void setSecureHealthCheckUrl(String secureHealthCheckUrl) {
|
||||
this.secureHealthCheckUrl = secureHealthCheckUrl;
|
||||
}
|
||||
|
||||
public String getNamespace() {
|
||||
return namespace;
|
||||
}
|
||||
|
||||
public void setNamespace(String namespace) {
|
||||
this.namespace = namespace;
|
||||
}
|
||||
|
||||
public boolean isPreferIpAddress() {
|
||||
return preferIpAddress;
|
||||
}
|
||||
|
||||
public void setPreferIpAddress(boolean preferIpAddress) {
|
||||
this.preferIpAddress = preferIpAddress;
|
||||
}
|
||||
|
||||
public InstanceStatus getInitialStatus() {
|
||||
return initialStatus;
|
||||
}
|
||||
|
||||
public void setInitialStatus(InstanceStatus initialStatus) {
|
||||
this.initialStatus = initialStatus;
|
||||
}
|
||||
|
||||
public String[] getDefaultAddressResolutionOrder() {
|
||||
return defaultAddressResolutionOrder;
|
||||
}
|
||||
|
||||
public void setDefaultAddressResolutionOrder(String[] defaultAddressResolutionOrder) {
|
||||
this.defaultAddressResolutionOrder = defaultAddressResolutionOrder;
|
||||
}
|
||||
|
||||
public Environment getEnvironment() {
|
||||
return environment;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
EurekaInstanceConfigBean that = (EurekaInstanceConfigBean) o;
|
||||
return Objects.equals(hostInfo, that.hostInfo) &&
|
||||
Objects.equals(inetUtils, that.inetUtils) &&
|
||||
Objects.equals(appname, that.appname) &&
|
||||
Objects.equals(appGroupName, that.appGroupName) &&
|
||||
instanceEnabledOnit == that.instanceEnabledOnit &&
|
||||
nonSecurePort == that.nonSecurePort &&
|
||||
securePort == that.securePort &&
|
||||
nonSecurePortEnabled == that.nonSecurePortEnabled &&
|
||||
securePortEnabled == that.securePortEnabled &&
|
||||
leaseRenewalIntervalInSeconds == that.leaseRenewalIntervalInSeconds &&
|
||||
leaseExpirationDurationInSeconds == that.leaseExpirationDurationInSeconds &&
|
||||
Objects.equals(virtualHostName, that.virtualHostName) &&
|
||||
Objects.equals(instanceId, that.instanceId) &&
|
||||
Objects.equals(secureVirtualHostName, that.secureVirtualHostName) &&
|
||||
Objects.equals(aSGName, that.aSGName) &&
|
||||
Objects.equals(metadataMap, that.metadataMap) &&
|
||||
Objects.equals(dataCenterInfo, that.dataCenterInfo) &&
|
||||
Objects.equals(ipAddress, that.ipAddress) &&
|
||||
Objects.equals(statusPageUrlPath, that.statusPageUrlPath) &&
|
||||
Objects.equals(statusPageUrl, that.statusPageUrl) &&
|
||||
Objects.equals(homePageUrlPath, that.homePageUrlPath) &&
|
||||
Objects.equals(homePageUrl, that.homePageUrl) &&
|
||||
Objects.equals(healthCheckUrlPath, that.healthCheckUrlPath) &&
|
||||
Objects.equals(healthCheckUrl, that.healthCheckUrl) &&
|
||||
Objects.equals(secureHealthCheckUrl, that.secureHealthCheckUrl) &&
|
||||
Objects.equals(namespace, that.namespace) &&
|
||||
Objects.equals(hostname, that.hostname) &&
|
||||
preferIpAddress == that.preferIpAddress &&
|
||||
Objects.equals(initialStatus, that.initialStatus) &&
|
||||
Arrays.equals(defaultAddressResolutionOrder, that.defaultAddressResolutionOrder) &&
|
||||
Objects.equals(environment, that.environment);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(hostInfo, inetUtils, appname, appGroupName,
|
||||
instanceEnabledOnit, nonSecurePort, securePort, nonSecurePortEnabled,
|
||||
securePortEnabled, leaseRenewalIntervalInSeconds,
|
||||
leaseExpirationDurationInSeconds, virtualHostName, instanceId,
|
||||
secureVirtualHostName, aSGName, metadataMap, dataCenterInfo, ipAddress,
|
||||
statusPageUrlPath, statusPageUrl, homePageUrlPath, homePageUrl,
|
||||
healthCheckUrlPath, healthCheckUrl, secureHealthCheckUrl, namespace,
|
||||
hostname, preferIpAddress, initialStatus, defaultAddressResolutionOrder, environment);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new StringBuilder("EurekaInstanceConfigBean{")
|
||||
.append("hostInfo=").append(hostInfo).append(", ")
|
||||
.append("inetUtils=").append(inetUtils).append(", ")
|
||||
.append("appname='").append(appname).append("', ")
|
||||
.append("appGroupName='").append(appGroupName).append("', ")
|
||||
.append("instanceEnabledOnit=").append(instanceEnabledOnit).append(", ")
|
||||
.append("nonSecurePort=").append(nonSecurePort).append(", ")
|
||||
.append("securePort=").append(securePort).append(", ")
|
||||
.append("nonSecurePortEnabled=").append(nonSecurePortEnabled).append(", ")
|
||||
.append("securePortEnabled=").append(securePortEnabled).append(", ")
|
||||
.append("leaseRenewalIntervalInSeconds=").append(leaseRenewalIntervalInSeconds).append(", ")
|
||||
.append("leaseExpirationDurationInSeconds=").append(leaseExpirationDurationInSeconds).append(", ")
|
||||
.append("virtualHostName='").append(virtualHostName).append("', ")
|
||||
.append("instanceId='").append(instanceId).append("', ")
|
||||
.append("secureVirtualHostName='").append(secureVirtualHostName).append("', ")
|
||||
.append("aSGName='").append(aSGName).append("', ")
|
||||
.append("metadataMap=").append(metadataMap).append(", ")
|
||||
.append("dataCenterInfo=").append(dataCenterInfo).append(", ")
|
||||
.append("ipAddress='").append(ipAddress).append("', ")
|
||||
.append("statusPageUrlPath='").append(statusPageUrlPath).append("', ")
|
||||
.append("statusPageUrl='").append(statusPageUrl).append("', ")
|
||||
.append("homePageUrlPath='").append(homePageUrlPath).append("', ")
|
||||
.append("homePageUrl='").append(homePageUrl).append("', ")
|
||||
.append("healthCheckUrlPath='").append(healthCheckUrlPath).append("', ")
|
||||
.append("healthCheckUrl='").append(healthCheckUrl).append("', ")
|
||||
.append("secureHealthCheckUrl='").append(secureHealthCheckUrl).append("', ")
|
||||
.append("namespace='").append(namespace).append("', ")
|
||||
.append("hostname='").append(hostname).append("', ")
|
||||
.append("preferIpAddress=").append(preferIpAddress).append(", ")
|
||||
.append("initialStatus=").append(initialStatus).append(", ")
|
||||
.append("defaultAddressResolutionOrder=").append(Arrays.toString(defaultAddressResolutionOrder)).append(", ")
|
||||
.append("environment=").append(environment).append(", ").append("}")
|
||||
.toString();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -19,9 +19,6 @@ package org.springframework.cloud.netflix.ribbon.eureka;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import com.netflix.appinfo.InstanceInfo;
|
||||
import com.netflix.client.config.CommonClientConfigKey;
|
||||
import com.netflix.client.config.IClientConfig;
|
||||
@@ -78,10 +75,18 @@ public class DomainExtractingServerList implements ServerList<DiscoveryEnabledSe
|
||||
|
||||
class DomainExtractingServer extends DiscoveryEnabledServer {
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
private String id;
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public DomainExtractingServer(DiscoveryEnabledServer server, boolean useSecurePort,
|
||||
boolean useIpAddr, boolean approximateZoneFromHostname) {
|
||||
// host and port are set in super()
|
||||
|
||||
Reference in New Issue
Block a user