Merge pull request #115321 from rphillips/fixes/linger_grpc_probes

Kubelet GRPC probes: improve network resources utilization
This commit is contained in:
Kubernetes Prow Robot 2023-01-26 15:56:24 -08:00 committed by GitHub
commit 6f22d1f1ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,6 +57,9 @@ func (p grpcProber) Probe(host, service string, port int, timeout time.Duration)
grpc.WithUserAgent(fmt.Sprintf("kube-probe/%s.%s", v.Major, v.Minor)),
grpc.WithBlock(),
grpc.WithTransportCredentials(insecure.NewCredentials()), //credentials are currently not supported
grpc.WithContextDialer(func(ctx context.Context, addr string) (net.Conn, error) {
return probe.ProbeDialer().DialContext(ctx, "tcp", addr)
}),
}
ctx, cancel := context.WithTimeout(context.Background(), timeout)