Browse Source

Make EurekaDiscoveryClient.EurekaServiceInstance constructor public (#1794)

Make EurekaDiscoveryClient.EurekaServiceInstance constructor public

fixes gh-1792
pull/6/head
Michael Tecourt 8 years ago committed by Spencer Gibb
parent
commit
03740f1369
  1. 4
      spring-cloud-netflix-eureka-client/src/main/java/org/springframework/cloud/netflix/eureka/EurekaDiscoveryClient.java

4
spring-cloud-netflix-eureka-client/src/main/java/org/springframework/cloud/netflix/eureka/EurekaDiscoveryClient.java

@ -27,6 +27,7 @@ import java.util.Map; @@ -27,6 +27,7 @@ import java.util.Map;
import org.springframework.cloud.client.DefaultServiceInstance;
import org.springframework.cloud.client.ServiceInstance;
import org.springframework.cloud.client.discovery.DiscoveryClient;
import org.springframework.util.Assert;
import com.netflix.appinfo.EurekaInstanceConfig;
import com.netflix.appinfo.InstanceInfo;
@ -102,7 +103,8 @@ public class EurekaDiscoveryClient implements DiscoveryClient { @@ -102,7 +103,8 @@ public class EurekaDiscoveryClient implements DiscoveryClient {
public static class EurekaServiceInstance implements ServiceInstance {
private InstanceInfo instance;
EurekaServiceInstance(InstanceInfo instance) {
public EurekaServiceInstance(InstanceInfo instance) {
Assert.notNull(instance, "Service instance required");
this.instance = instance;
}

Loading…
Cancel
Save