public class NacosBalancer
extends com.alibaba.nacos.client.naming.core.Balancer
| Constructor and Description |
|---|
NacosBalancer() |
| Modifier and Type | Method and Description |
|---|---|
static com.alibaba.nacos.api.naming.pojo.Instance |
getHostByRandomWeight2(List<com.alibaba.nacos.api.naming.pojo.Instance> instances)
Choose instance by weight.
|
static org.springframework.cloud.client.ServiceInstance |
getHostByRandomWeight3(List<org.springframework.cloud.client.ServiceInstance> serviceInstances)
Spring Cloud LoadBalancer Choose instance by weight.
|
public static com.alibaba.nacos.api.naming.pojo.Instance getHostByRandomWeight2(List<com.alibaba.nacos.api.naming.pojo.Instance> instances)
instances - Instance Listpublic static org.springframework.cloud.client.ServiceInstance getHostByRandomWeight3(List<org.springframework.cloud.client.ServiceInstance> serviceInstances)
serviceInstances - Instance ListCopyright © 2023 Pivotal Software, Inc.. All rights reserved.