Skip to content

Commit

Permalink
feat(transport): remove grpc version guard (#1506)
Browse files Browse the repository at this point in the history
  • Loading branch information
mohanli-ml committed Apr 11, 2022
1 parent eeb33c7 commit d349e85
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions transport/grpc/dial.go
Expand Up @@ -150,8 +150,7 @@ func dial(ctx context.Context, insecure bool, o *internal.DialSettings) (*grpc.C
grpcOpts = append(grpcOpts, timeoutDialerOption)
}
// Check if google-c2p resolver is enabled for DirectPath
// TODO(mohanli): remove grpc version guard once google-api-go-client is able to depends on the latest grpc
if grpc.Version >= "1.42" && strings.EqualFold(os.Getenv(enableDirectPathXds), "true") {
if strings.EqualFold(os.Getenv(enableDirectPathXds), "true") {
// google-c2p resolver target must not have a port number
if addr, _, err := net.SplitHostPort(endpoint); err == nil {
endpoint = "google-c2p-experimental:///" + addr
Expand Down

0 comments on commit d349e85

Please sign in to comment.