public class RibbonLoadBalancerClient extends Object implements org.springframework.cloud.client.loadbalancer.LoadBalancerClient
Modifier and Type | Class and Description |
---|---|
static class |
RibbonLoadBalancerClient.RibbonServer |
Constructor and Description |
---|
RibbonLoadBalancerClient(SpringClientFactory clientFactory) |
Modifier and Type | Method and Description |
---|---|
org.springframework.cloud.client.ServiceInstance |
choose(String serviceId) |
<T> T |
execute(String serviceId,
org.springframework.cloud.client.loadbalancer.LoadBalancerRequest<T> request) |
<T> T |
execute(String serviceId,
org.springframework.cloud.client.ServiceInstance serviceInstance,
org.springframework.cloud.client.loadbalancer.LoadBalancerRequest<T> request) |
protected com.netflix.loadbalancer.ILoadBalancer |
getLoadBalancer(String serviceId) |
protected com.netflix.loadbalancer.Server |
getServer(com.netflix.loadbalancer.ILoadBalancer loadBalancer) |
protected com.netflix.loadbalancer.Server |
getServer(String serviceId) |
URI |
reconstructURI(org.springframework.cloud.client.ServiceInstance instance,
URI original) |
public RibbonLoadBalancerClient(SpringClientFactory clientFactory)
public URI reconstructURI(org.springframework.cloud.client.ServiceInstance instance, URI original)
reconstructURI
in interface org.springframework.cloud.client.loadbalancer.LoadBalancerClient
public org.springframework.cloud.client.ServiceInstance choose(String serviceId)
choose
in interface org.springframework.cloud.client.loadbalancer.ServiceInstanceChooser
public <T> T execute(String serviceId, org.springframework.cloud.client.loadbalancer.LoadBalancerRequest<T> request) throws IOException
execute
in interface org.springframework.cloud.client.loadbalancer.LoadBalancerClient
IOException
public <T> T execute(String serviceId, org.springframework.cloud.client.ServiceInstance serviceInstance, org.springframework.cloud.client.loadbalancer.LoadBalancerRequest<T> request) throws IOException
execute
in interface org.springframework.cloud.client.loadbalancer.LoadBalancerClient
IOException
protected com.netflix.loadbalancer.Server getServer(String serviceId)
protected com.netflix.loadbalancer.Server getServer(com.netflix.loadbalancer.ILoadBalancer loadBalancer)
protected com.netflix.loadbalancer.ILoadBalancer getLoadBalancer(String serviceId)
Copyright © 2017 Pivotal Software, Inc.. All rights reserved.