Remove deprecated netflix-core dependency.
This commit is contained in:
@@ -33,7 +33,7 @@
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-netflix-core</artifactId>
|
||||
<artifactId>spring-cloud-netflix-hystrix</artifactId>
|
||||
<optional>true</optional>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
||||
@@ -81,8 +81,8 @@ public class CloudFoundryDiscoveryClient implements DiscoveryClient {
|
||||
metadata.put("applicationId", applicationId);
|
||||
metadata.put("instanceId", applicationIndex);
|
||||
|
||||
return (ServiceInstance) new DefaultServiceInstance(instanceId, name, url, 80, secure,
|
||||
metadata);
|
||||
return (ServiceInstance) new DefaultServiceInstance(instanceId, name, url, 80,
|
||||
secure, metadata);
|
||||
}).collectList().blockOptional().orElse(new ArrayList<>());
|
||||
}
|
||||
|
||||
|
||||
@@ -92,7 +92,8 @@ public class CloudFoundryDiscoveryClientTest {
|
||||
List<ServiceInstance> instances = this.cloudFoundryDiscoveryClient
|
||||
.getInstances(this.hiServiceServiceId);
|
||||
assertThat(instances.size()).as("Wrong instances: " + instances).isEqualTo(1);
|
||||
assertThat(instances.get(0).getInstanceId()).as("Wrong instance ID").isEqualTo("id.0");
|
||||
assertThat(instances.get(0).getInstanceId()).as("Wrong instance ID")
|
||||
.isEqualTo("id.0");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user