Class ServiceInstanceListRoundRobinLoadBalancer
java.lang.Object
io.micronaut.http.client.loadbalance.AbstractRoundRobinLoadBalancer
io.micronaut.http.client.loadbalance.ServiceInstanceListRoundRobinLoadBalancer
- All Implemented Interfaces:
LoadBalancer
- Since:
- 1.0
- Author:
- Graeme Rocher
-
Field Summary
Fields inherited from class io.micronaut.http.client.loadbalance.AbstractRoundRobinLoadBalancer
index
-
Constructor Summary
ConstructorDescriptionServiceInstanceListRoundRobinLoadBalancer
(ServiceInstanceList serviceInstanceList) -
Method Summary
Modifier and TypeMethodDescriptionMethods inherited from class io.micronaut.http.client.loadbalance.AbstractRoundRobinLoadBalancer
getNextAvailable
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.http.client.LoadBalancer
select
-
Constructor Details
-
ServiceInstanceListRoundRobinLoadBalancer
- Parameters:
serviceInstanceList
- The service instance list
-
-
Method Details
-
select
- Parameters:
discriminator
- An object used to discriminate the server to select. Usually the service ID- Returns:
- The selected
ServiceInstance
-
getServiceID
- Specified by:
getServiceID
in classAbstractRoundRobinLoadBalancer
- Returns:
- The service ID
-
getContextPath
- Returns:
- The context path to use for requests.
-