From 5989bb18613c2b1fc1027819185733aca0f2d138 Mon Sep 17 00:00:00 2001 From: Mohan Li <67390330+mohanli-ml@users.noreply.github.com> Date: Wed, 14 Dec 2022 10:03:29 -0800 Subject: [PATCH] feat(bigtable): install grpc rls and xds by default (#6005) * feat(bigtable): install grpc rls and xds by default Co-authored-by: Eric Schmidt --- bigtable/bigtable.go | 5 +++++ bigtable/bigtable_enablexds.go | 22 ---------------------- 2 files changed, 5 insertions(+), 22 deletions(-) delete mode 100644 bigtable/bigtable_enablexds.go diff --git a/bigtable/bigtable.go b/bigtable/bigtable.go index 01c6bb83b02..24a3e20fa8d 100644 --- a/bigtable/bigtable.go +++ b/bigtable/bigtable.go @@ -37,6 +37,11 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" + + // Install google-c2p resolver, which is required for direct path. + _ "google.golang.org/grpc/xds/googledirectpath" + // Install RLS load balancer policy, which is needed for gRPC RLS. + _ "google.golang.org/grpc/balancer/rls" ) const prodAddr = "bigtable.googleapis.com:443" diff --git a/bigtable/bigtable_enablexds.go b/bigtable/bigtable_enablexds.go deleted file mode 100644 index 08a9d9b40dc..00000000000 --- a/bigtable/bigtable_enablexds.go +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2021 Google LLC -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -//go:build enablexds -// +build enablexds - -package bigtable - -import ( - // Install google-c2p resolver, which is required for direct path. - _ "google.golang.org/grpc/xds/googledirectpath" -)