public class RandomServiceInstanceSelector extends Object implements ServiceInstanceSelector
ServiceInstanceSelector implementation based on Random algorithmThreadLocalRandom,
ServiceInstanceSelector| Constructor and Description |
|---|
RandomServiceInstanceSelector() |
| Modifier and Type | Method and Description |
|---|---|
ServiceInstance |
select(URL registryURL,
List<ServiceInstance> serviceInstances)
Select an instance of
ServiceInstance by the specified service instances |
public ServiceInstance select(URL registryURL, List<ServiceInstance> serviceInstances)
ServiceInstanceSelectorServiceInstance by the specified service instancesselect in interface ServiceInstanceSelectorregistryURL - The url of registryserviceInstances - the specified service instancesServiceInstance if available, or nullCopyright © 2011–2019 The Apache Software Foundation. All rights reserved.