grpc: move to use grpc.WithTransportCredentials()
v1.43.0 marked grpc.WithInsecure() deprecated so this commit moves to use what is the recommended replacement: grpc.WithTransportCredentials(insecure.NewCredentials()) Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
This commit is contained in:
@@ -24,6 +24,7 @@ import (
|
||||
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/credentials/insecure"
|
||||
grpchealth "google.golang.org/grpc/health/grpc_health_v1"
|
||||
"google.golang.org/grpc/metadata"
|
||||
"google.golang.org/grpc/status"
|
||||
@@ -55,7 +56,7 @@ func (p grpcProber) Probe(host, service string, port int, timeout time.Duration)
|
||||
opts := []grpc.DialOption{
|
||||
grpc.WithUserAgent(fmt.Sprintf("kube-probe/%s.%s", v.Major, v.Minor)),
|
||||
grpc.WithBlock(),
|
||||
grpc.WithInsecure(), //credentials are currently not supported
|
||||
grpc.WithTransportCredentials(insecure.NewCredentials()), //credentials are currently not supported
|
||||
}
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), timeout)
|
||||
|
Reference in New Issue
Block a user