mirror of https://github.com/grpc/grpc-java.git
core: OutlierDetectionLoadBalancer to pass child LB config. (#9467)
This commit is contained in:
parent
9ed5a1bbbf
commit
f5670b39c4
|
|
@ -139,7 +139,9 @@ public final class OutlierDetectionLoadBalancer extends LoadBalancer {
|
||||||
trackerMap.cancelTracking();
|
trackerMap.cancelTracking();
|
||||||
}
|
}
|
||||||
|
|
||||||
switchLb.handleResolvedAddresses(resolvedAddresses);
|
switchLb.handleResolvedAddresses(
|
||||||
|
resolvedAddresses.toBuilder().setLoadBalancingPolicyConfig(config.childPolicy.getConfig())
|
||||||
|
.build());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
||||||
|
|
@ -233,7 +233,9 @@ public class OutlierDetectionLoadBalancerTest {
|
||||||
loadBalancer.handleResolvedAddresses(resolvedAddresses);
|
loadBalancer.handleResolvedAddresses(resolvedAddresses);
|
||||||
|
|
||||||
// Handling of resolved addresses is delegated
|
// Handling of resolved addresses is delegated
|
||||||
verify(mockChildLb).handleResolvedAddresses(resolvedAddresses);
|
verify(mockChildLb).handleResolvedAddresses(
|
||||||
|
resolvedAddresses.toBuilder().setLoadBalancingPolicyConfig(config.childPolicy.getConfig())
|
||||||
|
.build());
|
||||||
|
|
||||||
// There is a single pending task to run the outlier detection algorithm
|
// There is a single pending task to run the outlier detection algorithm
|
||||||
assertThat(fakeClock.getPendingTasks()).hasSize(1);
|
assertThat(fakeClock.getPendingTasks()).hasSize(1);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue