[VOL-4442] grpc streaming connection monitoring
Change-Id: Id787e94cf28745d36e72f8ed2f5c316312714db4
diff --git a/vendor/google.golang.org/grpc/internal/channelz/funcs.go b/vendor/google.golang.org/grpc/internal/channelz/funcs.go
index 6d5760d..cd18075 100644
--- a/vendor/google.golang.org/grpc/internal/channelz/funcs.go
+++ b/vendor/google.golang.org/grpc/internal/channelz/funcs.go
@@ -204,9 +204,9 @@
trace: &channelTrace{createdTime: time.Now(), events: make([]*TraceEvent, 0, getMaxTraceEntry())},
}
if pid == 0 {
- db.get().addChannel(id, cn, true, pid, ref)
+ db.get().addChannel(id, cn, true, pid)
} else {
- db.get().addChannel(id, cn, false, pid, ref)
+ db.get().addChannel(id, cn, false, pid)
}
return id
}
@@ -228,7 +228,7 @@
pid: pid,
trace: &channelTrace{createdTime: time.Now(), events: make([]*TraceEvent, 0, getMaxTraceEntry())},
}
- db.get().addSubChannel(id, sc, pid, ref)
+ db.get().addSubChannel(id, sc, pid)
return id
}
@@ -258,7 +258,7 @@
}
id := idGen.genID()
ls := &listenSocket{refName: ref, s: s, id: id, pid: pid}
- db.get().addListenSocket(id, ls, pid, ref)
+ db.get().addListenSocket(id, ls, pid)
return id
}
@@ -273,11 +273,11 @@
}
id := idGen.genID()
ns := &normalSocket{refName: ref, s: s, id: id, pid: pid}
- db.get().addNormalSocket(id, ns, pid, ref)
+ db.get().addNormalSocket(id, ns, pid)
return id
}
-// RemoveEntry removes an entry with unique channelz trakcing id to be id from
+// RemoveEntry removes an entry with unique channelz tracking id to be id from
// channelz database.
func RemoveEntry(id int64) {
db.get().removeEntry(id)
@@ -333,7 +333,7 @@
c.mu.Unlock()
}
-func (c *channelMap) addChannel(id int64, cn *channel, isTopChannel bool, pid int64, ref string) {
+func (c *channelMap) addChannel(id int64, cn *channel, isTopChannel bool, pid int64) {
c.mu.Lock()
cn.cm = c
cn.trace.cm = c
@@ -346,7 +346,7 @@
c.mu.Unlock()
}
-func (c *channelMap) addSubChannel(id int64, sc *subChannel, pid int64, ref string) {
+func (c *channelMap) addSubChannel(id int64, sc *subChannel, pid int64) {
c.mu.Lock()
sc.cm = c
sc.trace.cm = c
@@ -355,7 +355,7 @@
c.mu.Unlock()
}
-func (c *channelMap) addListenSocket(id int64, ls *listenSocket, pid int64, ref string) {
+func (c *channelMap) addListenSocket(id int64, ls *listenSocket, pid int64) {
c.mu.Lock()
ls.cm = c
c.listenSockets[id] = ls
@@ -363,7 +363,7 @@
c.mu.Unlock()
}
-func (c *channelMap) addNormalSocket(id int64, ns *normalSocket, pid int64, ref string) {
+func (c *channelMap) addNormalSocket(id int64, ns *normalSocket, pid int64) {
c.mu.Lock()
ns.cm = c
c.normalSockets[id] = ns
diff --git a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
index 9f25a67..6f02725 100644
--- a/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
+++ b/vendor/google.golang.org/grpc/internal/envconfig/envconfig.go
@@ -22,20 +22,14 @@
import (
"os"
"strings"
-
- xdsenv "google.golang.org/grpc/internal/xds/env"
)
const (
prefix = "GRPC_GO_"
- retryStr = prefix + "RETRY"
txtErrIgnoreStr = prefix + "IGNORE_TXT_ERRORS"
)
var (
- // Retry is enabled unless explicitly disabled via "GRPC_GO_RETRY=off" or
- // if XDS retry support is explicitly disabled.
- Retry = !strings.EqualFold(os.Getenv(retryStr), "off") && xdsenv.RetrySupport
// TXTErrIgnore is set if TXT errors should be ignored ("GRPC_GO_IGNORE_TXT_ERRORS" is not "false").
TXTErrIgnore = !strings.EqualFold(os.Getenv(txtErrIgnoreStr), "false")
)
diff --git a/vendor/google.golang.org/grpc/internal/envconfig/xds.go b/vendor/google.golang.org/grpc/internal/envconfig/xds.go
new file mode 100644
index 0000000..9bad03c
--- /dev/null
+++ b/vendor/google.golang.org/grpc/internal/envconfig/xds.go
@@ -0,0 +1,97 @@
+/*
+ *
+ * Copyright 2020 gRPC authors.
+ *
+ * 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.
+ *
+ */
+
+package envconfig
+
+import (
+ "os"
+ "strings"
+)
+
+const (
+ // XDSBootstrapFileNameEnv is the env variable to set bootstrap file name.
+ // Do not use this and read from env directly. Its value is read and kept in
+ // variable BootstrapFileName.
+ //
+ // When both bootstrap FileName and FileContent are set, FileName is used.
+ XDSBootstrapFileNameEnv = "GRPC_XDS_BOOTSTRAP"
+ // XDSBootstrapFileContentEnv is the env variable to set bootstrapp file
+ // content. Do not use this and read from env directly. Its value is read
+ // and kept in variable BootstrapFileName.
+ //
+ // When both bootstrap FileName and FileContent are set, FileName is used.
+ XDSBootstrapFileContentEnv = "GRPC_XDS_BOOTSTRAP_CONFIG"
+
+ ringHashSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH"
+ clientSideSecuritySupportEnv = "GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT"
+ aggregateAndDNSSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER"
+ rbacSupportEnv = "GRPC_XDS_EXPERIMENTAL_RBAC"
+ federationEnv = "GRPC_EXPERIMENTAL_XDS_FEDERATION"
+ rlsInXDSEnv = "GRPC_EXPERIMENTAL_XDS_RLS_LB"
+
+ c2pResolverTestOnlyTrafficDirectorURIEnv = "GRPC_TEST_ONLY_GOOGLE_C2P_RESOLVER_TRAFFIC_DIRECTOR_URI"
+)
+
+var (
+ // XDSBootstrapFileName holds the name of the file which contains xDS
+ // bootstrap configuration. Users can specify the location of the bootstrap
+ // file by setting the environment variable "GRPC_XDS_BOOTSTRAP".
+ //
+ // When both bootstrap FileName and FileContent are set, FileName is used.
+ XDSBootstrapFileName = os.Getenv(XDSBootstrapFileNameEnv)
+ // XDSBootstrapFileContent holds the content of the xDS bootstrap
+ // configuration. Users can specify the bootstrap config by setting the
+ // environment variable "GRPC_XDS_BOOTSTRAP_CONFIG".
+ //
+ // When both bootstrap FileName and FileContent are set, FileName is used.
+ XDSBootstrapFileContent = os.Getenv(XDSBootstrapFileContentEnv)
+ // XDSRingHash indicates whether ring hash support is enabled, which can be
+ // disabled by setting the environment variable
+ // "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH" to "false".
+ XDSRingHash = !strings.EqualFold(os.Getenv(ringHashSupportEnv), "false")
+ // XDSClientSideSecurity is used to control processing of security
+ // configuration on the client-side.
+ //
+ // Note that there is no env var protection for the server-side because we
+ // have a brand new API on the server-side and users explicitly need to use
+ // the new API to get security integration on the server.
+ XDSClientSideSecurity = !strings.EqualFold(os.Getenv(clientSideSecuritySupportEnv), "false")
+ // XDSAggregateAndDNS indicates whether processing of aggregated cluster
+ // and DNS cluster is enabled, which can be enabled by setting the
+ // environment variable
+ // "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER" to
+ // "true".
+ XDSAggregateAndDNS = strings.EqualFold(os.Getenv(aggregateAndDNSSupportEnv), "true")
+
+ // XDSRBAC indicates whether xDS configured RBAC HTTP Filter is enabled,
+ // which can be disabled by setting the environment variable
+ // "GRPC_XDS_EXPERIMENTAL_RBAC" to "false".
+ XDSRBAC = !strings.EqualFold(os.Getenv(rbacSupportEnv), "false")
+
+ // XDSFederation indicates whether federation support is enabled.
+ XDSFederation = strings.EqualFold(os.Getenv(federationEnv), "true")
+
+ // XDSRLS indicates whether processing of Cluster Specifier plugins and
+ // support for the RLS CLuster Specifier is enabled, which can be enabled by
+ // setting the environment variable "GRPC_EXPERIMENTAL_XDS_RLS_LB" to
+ // "true".
+ XDSRLS = strings.EqualFold(os.Getenv(rlsInXDSEnv), "true")
+
+ // C2PResolverTestOnlyTrafficDirectorURI is the TD URI for testing.
+ C2PResolverTestOnlyTrafficDirectorURI = os.Getenv(c2pResolverTestOnlyTrafficDirectorURIEnv)
+)
diff --git a/vendor/google.golang.org/grpc/internal/grpclog/grpclog.go b/vendor/google.golang.org/grpc/internal/grpclog/grpclog.go
index e6f975c..30a3b42 100644
--- a/vendor/google.golang.org/grpc/internal/grpclog/grpclog.go
+++ b/vendor/google.golang.org/grpc/internal/grpclog/grpclog.go
@@ -115,12 +115,12 @@
// Notice: This type is EXPERIMENTAL and may be changed or removed in a
// later release.
type DepthLoggerV2 interface {
- // InfoDepth logs to INFO log at the specified depth. Arguments are handled in the manner of fmt.Print.
+ // InfoDepth logs to INFO log at the specified depth. Arguments are handled in the manner of fmt.Println.
InfoDepth(depth int, args ...interface{})
- // WarningDepth logs to WARNING log at the specified depth. Arguments are handled in the manner of fmt.Print.
+ // WarningDepth logs to WARNING log at the specified depth. Arguments are handled in the manner of fmt.Println.
WarningDepth(depth int, args ...interface{})
- // ErrorDetph logs to ERROR log at the specified depth. Arguments are handled in the manner of fmt.Print.
+ // ErrorDepth logs to ERROR log at the specified depth. Arguments are handled in the manner of fmt.Println.
ErrorDepth(depth int, args ...interface{})
- // FatalDepth logs to FATAL log at the specified depth. Arguments are handled in the manner of fmt.Print.
+ // FatalDepth logs to FATAL log at the specified depth. Arguments are handled in the manner of fmt.Println.
FatalDepth(depth int, args ...interface{})
}
diff --git a/vendor/google.golang.org/grpc/internal/grpcutil/regex.go b/vendor/google.golang.org/grpc/internal/grpcutil/regex.go
index 2810a8b..7a092b2 100644
--- a/vendor/google.golang.org/grpc/internal/grpcutil/regex.go
+++ b/vendor/google.golang.org/grpc/internal/grpcutil/regex.go
@@ -20,9 +20,12 @@
import "regexp"
-// FullMatchWithRegex returns whether the full string matches the regex provided.
-func FullMatchWithRegex(re *regexp.Regexp, string string) bool {
+// FullMatchWithRegex returns whether the full text matches the regex provided.
+func FullMatchWithRegex(re *regexp.Regexp, text string) bool {
+ if len(text) == 0 {
+ return re.MatchString(text)
+ }
re.Longest()
- rem := re.FindString(string)
- return len(rem) == len(string)
+ rem := re.FindString(text)
+ return len(rem) == len(text)
}
diff --git a/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go b/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
index f262edd..97198c5 100644
--- a/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
+++ b/vendor/google.golang.org/grpc/internal/transport/flowcontrol.go
@@ -136,12 +136,10 @@
// newLimit updates the inflow window to a new value n.
// It assumes that n is always greater than the old limit.
-func (f *inFlow) newLimit(n uint32) uint32 {
+func (f *inFlow) newLimit(n uint32) {
f.mu.Lock()
- d := n - f.limit
f.limit = n
f.mu.Unlock()
- return d
}
func (f *inFlow) maybeAdjust(n uint32) uint32 {
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_client.go b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
index 2521a7d..f0c72d3 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_client.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_client.go
@@ -201,6 +201,12 @@
}
}()
+ // gRPC, resolver, balancer etc. can specify arbitrary data in the
+ // Attributes field of resolver.Address, which is shoved into connectCtx
+ // and passed to the dialer and credential handshaker. This makes it possible for
+ // address specific arbitrary data to reach custom dialers and credential handshakers.
+ connectCtx = icredentials.NewClientHandshakeInfoContext(connectCtx, credentials.ClientHandshakeInfo{Attributes: addr.Attributes})
+
conn, err := dial(connectCtx, opts.Dialer, addr, opts.UseProxy, opts.UserAgent)
if err != nil {
if opts.FailOnNonTempDialError {
@@ -245,11 +251,6 @@
}
}
if transportCreds != nil {
- // gRPC, resolver, balancer etc. can specify arbitrary data in the
- // Attributes field of resolver.Address, which is shoved into connectCtx
- // and passed to the credential handshaker. This makes it possible for
- // address specific arbitrary data to reach the credential handshaker.
- connectCtx = icredentials.NewClientHandshakeInfoContext(connectCtx, credentials.ClientHandshakeInfo{Attributes: addr.Attributes})
rawConn := conn
// Pull the deadline from the connectCtx, which will be used for
// timeouts in the authentication protocol handshake. Can ignore the
@@ -587,7 +588,7 @@
return nil, err
}
- return nil, status.Errorf(codes.Unauthenticated, "transport: %v", err)
+ return nil, status.Errorf(codes.Unauthenticated, "transport: per-RPC creds failed due to error: %v", err)
}
for k, v := range data {
// Capital header names are illegal in HTTP/2.
@@ -1556,7 +1557,7 @@
return b
}
-// keepalive running in a separate goroutune makes sure the connection is alive by sending pings.
+// keepalive running in a separate goroutine makes sure the connection is alive by sending pings.
func (t *http2Client) keepalive() {
p := &ping{data: [8]byte{}}
// True iff a ping has been sent, and no data has been received since then.
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_server.go b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
index f2cad9e..2c6eaf0 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_server.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
@@ -73,7 +73,6 @@
writerDone chan struct{} // sync point to enable testing.
remoteAddr net.Addr
localAddr net.Addr
- maxStreamID uint32 // max stream ID ever seen
authInfo credentials.AuthInfo // auth info about the connection
inTapHandle tap.ServerInHandle
framer *framer
@@ -123,6 +122,11 @@
bufferPool *bufferPool
connectionID uint64
+
+ // maxStreamMu guards the maximum stream ID
+ // This lock may not be taken if mu is already held.
+ maxStreamMu sync.Mutex
+ maxStreamID uint32 // max stream ID ever seen
}
// NewServerTransport creates a http2 transport with conn and configuration
@@ -334,6 +338,10 @@
// operateHeader takes action on the decoded headers.
func (t *http2Server) operateHeaders(frame *http2.MetaHeadersFrame, handle func(*Stream), traceCtx func(context.Context, string) context.Context) (fatal bool) {
+ // Acquire max stream ID lock for entire duration
+ t.maxStreamMu.Lock()
+ defer t.maxStreamMu.Unlock()
+
streamID := frame.Header().StreamID
// frame.Truncated is set to true when framer detects that the current header
@@ -348,6 +356,15 @@
return false
}
+ if streamID%2 != 1 || streamID <= t.maxStreamID {
+ // illegal gRPC stream id.
+ if logger.V(logLevel) {
+ logger.Errorf("transport: http2Server.HandleStreams received an illegal stream id: %v", streamID)
+ }
+ return true
+ }
+ t.maxStreamID = streamID
+
buf := newRecvBuffer()
s := &Stream{
id: streamID,
@@ -355,7 +372,6 @@
buf: buf,
fc: &inFlow{limit: uint32(t.initialWindowSize)},
}
-
var (
// If a gRPC Response-Headers has already been received, then it means
// that the peer is speaking gRPC and we are in gRPC mode.
@@ -498,16 +514,6 @@
s.cancel()
return false
}
- if streamID%2 != 1 || streamID <= t.maxStreamID {
- t.mu.Unlock()
- // illegal gRPC stream id.
- if logger.V(logLevel) {
- logger.Errorf("transport: http2Server.HandleStreams received an illegal stream id: %v", streamID)
- }
- s.cancel()
- return true
- }
- t.maxStreamID = streamID
if httpMethod != http.MethodPost {
t.mu.Unlock()
if logger.V(logLevel) {
@@ -1293,20 +1299,23 @@
// Handles outgoing GoAway and returns true if loopy needs to put itself
// in draining mode.
func (t *http2Server) outgoingGoAwayHandler(g *goAway) (bool, error) {
+ t.maxStreamMu.Lock()
t.mu.Lock()
if t.state == closing { // TODO(mmukhi): This seems unnecessary.
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
// The transport is closing.
return false, ErrConnClosing
}
- sid := t.maxStreamID
if !g.headsUp {
// Stop accepting more streams now.
t.state = draining
+ sid := t.maxStreamID
if len(t.activeStreams) == 0 {
g.closeConn = true
}
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
if err := t.framer.fr.WriteGoAway(sid, g.code, g.debugData); err != nil {
return false, err
}
@@ -1319,6 +1328,7 @@
return true, nil
}
t.mu.Unlock()
+ t.maxStreamMu.Unlock()
// For a graceful close, send out a GoAway with stream ID of MaxUInt32,
// Follow that with a ping and wait for the ack to come back or a timer
// to expire. During this time accept new streams since they might have
diff --git a/vendor/google.golang.org/grpc/internal/transport/proxy.go b/vendor/google.golang.org/grpc/internal/transport/proxy.go
index a662bf3..4159619 100644
--- a/vendor/google.golang.org/grpc/internal/transport/proxy.go
+++ b/vendor/google.golang.org/grpc/internal/transport/proxy.go
@@ -37,7 +37,7 @@
httpProxyFromEnvironment = http.ProxyFromEnvironment
)
-func mapAddress(ctx context.Context, address string) (*url.URL, error) {
+func mapAddress(address string) (*url.URL, error) {
req := &http.Request{
URL: &url.URL{
Scheme: "https",
@@ -114,7 +114,7 @@
// connection.
func proxyDial(ctx context.Context, addr string, grpcUA string) (conn net.Conn, err error) {
newAddr := addr
- proxyURL, err := mapAddress(ctx, addr)
+ proxyURL, err := mapAddress(addr)
if err != nil {
return nil, err
}
diff --git a/vendor/google.golang.org/grpc/internal/xds/env/env.go b/vendor/google.golang.org/grpc/internal/xds/env/env.go
deleted file mode 100644
index 87d3c24..0000000
--- a/vendor/google.golang.org/grpc/internal/xds/env/env.go
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- *
- * Copyright 2020 gRPC authors.
- *
- * 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.
- *
- */
-
-// Package env acts a single source of definition for all environment variables
-// related to the xDS implementation in gRPC.
-package env
-
-import (
- "os"
- "strings"
-)
-
-const (
- // BootstrapFileNameEnv is the env variable to set bootstrap file name.
- // Do not use this and read from env directly. Its value is read and kept in
- // variable BootstrapFileName.
- //
- // When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileNameEnv = "GRPC_XDS_BOOTSTRAP"
- // BootstrapFileContentEnv is the env variable to set bootstrapp file
- // content. Do not use this and read from env directly. Its value is read
- // and kept in variable BootstrapFileName.
- //
- // When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileContentEnv = "GRPC_XDS_BOOTSTRAP_CONFIG"
-
- ringHashSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH"
- clientSideSecuritySupportEnv = "GRPC_XDS_EXPERIMENTAL_SECURITY_SUPPORT"
- aggregateAndDNSSupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER"
- retrySupportEnv = "GRPC_XDS_EXPERIMENTAL_ENABLE_RETRY"
- rbacSupportEnv = "GRPC_XDS_EXPERIMENTAL_RBAC"
-
- c2pResolverSupportEnv = "GRPC_EXPERIMENTAL_GOOGLE_C2P_RESOLVER"
- c2pResolverTestOnlyTrafficDirectorURIEnv = "GRPC_TEST_ONLY_GOOGLE_C2P_RESOLVER_TRAFFIC_DIRECTOR_URI"
-)
-
-var (
- // BootstrapFileName holds the name of the file which contains xDS bootstrap
- // configuration. Users can specify the location of the bootstrap file by
- // setting the environment variable "GRPC_XDS_BOOTSTRAP".
- //
- // When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileName = os.Getenv(BootstrapFileNameEnv)
- // BootstrapFileContent holds the content of the xDS bootstrap
- // configuration. Users can specify the bootstrap config by
- // setting the environment variable "GRPC_XDS_BOOTSTRAP_CONFIG".
- //
- // When both bootstrap FileName and FileContent are set, FileName is used.
- BootstrapFileContent = os.Getenv(BootstrapFileContentEnv)
- // RingHashSupport indicates whether ring hash support is enabled, which can
- // be disabled by setting the environment variable
- // "GRPC_XDS_EXPERIMENTAL_ENABLE_RING_HASH" to "false".
- RingHashSupport = !strings.EqualFold(os.Getenv(ringHashSupportEnv), "false")
- // ClientSideSecuritySupport is used to control processing of security
- // configuration on the client-side.
- //
- // Note that there is no env var protection for the server-side because we
- // have a brand new API on the server-side and users explicitly need to use
- // the new API to get security integration on the server.
- ClientSideSecuritySupport = !strings.EqualFold(os.Getenv(clientSideSecuritySupportEnv), "false")
- // AggregateAndDNSSupportEnv indicates whether processing of aggregated
- // cluster and DNS cluster is enabled, which can be enabled by setting the
- // environment variable
- // "GRPC_XDS_EXPERIMENTAL_ENABLE_AGGREGATE_AND_LOGICAL_DNS_CLUSTER" to
- // "true".
- AggregateAndDNSSupportEnv = strings.EqualFold(os.Getenv(aggregateAndDNSSupportEnv), "true")
-
- // RetrySupport indicates whether xDS retry is enabled.
- RetrySupport = !strings.EqualFold(os.Getenv(retrySupportEnv), "false")
-
- // RBACSupport indicates whether xDS configured RBAC HTTP Filter is enabled,
- // which can be disabled by setting the environment variable
- // "GRPC_XDS_EXPERIMENTAL_RBAC" to "false".
- RBACSupport = !strings.EqualFold(os.Getenv(rbacSupportEnv), "false")
-
- // C2PResolverSupport indicates whether support for C2P resolver is enabled.
- // This can be enabled by setting the environment variable
- // "GRPC_EXPERIMENTAL_GOOGLE_C2P_RESOLVER" to "true".
- C2PResolverSupport = strings.EqualFold(os.Getenv(c2pResolverSupportEnv), "true")
- // C2PResolverTestOnlyTrafficDirectorURI is the TD URI for testing.
- C2PResolverTestOnlyTrafficDirectorURI = os.Getenv(c2pResolverTestOnlyTrafficDirectorURIEnv)
-)