Skip to content

Commit de957a9

Browse files
committed
outlier detection configuration for etcd client
1 parent 3d07014 commit de957a9

File tree

1 file changed

+23
-0
lines changed
  • staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory

1 file changed

+23
-0
lines changed

staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/etcd3.go

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -314,6 +314,29 @@ var newETCD3Client = func(c storagebackend.TransportConfig) (*clientv3.Client, e
314314
// which seems to be what we want as the metrics will be collected on each attempt (retry)
315315
grpc.WithChainUnaryInterceptor(grpcprom.UnaryClientInterceptor),
316316
grpc.WithChainStreamInterceptor(grpcprom.StreamClientInterceptor),
317+
grpc.WithDefaultServiceConfig(`
318+
{
319+
"loadBalancingConfig": [
320+
{
321+
"outlier_detection_experimental": {
322+
"interval": "2s",
323+
"baseEjectionTime": "30s",
324+
"maxEjectionTime": "300s",
325+
"maxEjectionPercent": 10,
326+
"failurePercentageEjection": {
327+
"threshold": 85,
328+
"enforcementPercentage": 100,
329+
"minimumHosts": 3,
330+
"requestVolume": 5
331+
},
332+
"childPolicy": [{"round_robin": {}}]
333+
}
334+
}
335+
],
336+
"healthCheckConfig": {
337+
"serviceName": ""
338+
}
339+
}`),
317340
}
318341
if utilfeature.DefaultFeatureGate.Enabled(genericfeatures.APIServerTracing) {
319342
tracingOpts := []otelgrpc.Option{

0 commit comments

Comments
 (0)