From f74d78060947ca809d23b268c96234f8e20e7e97 Mon Sep 17 00:00:00 2001 From: Menghan Li Date: Thu, 2 Dec 2021 10:28:25 -0800 Subject: [PATCH] [bootstrap_config_export_field] c --- xds/internal/xdsclient/bootstrap/bootstrap.go | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/xds/internal/xdsclient/bootstrap/bootstrap.go b/xds/internal/xdsclient/bootstrap/bootstrap.go index 603f6d94174..ecec170774c 100644 --- a/xds/internal/xdsclient/bootstrap/bootstrap.go +++ b/xds/internal/xdsclient/bootstrap/bootstrap.go @@ -88,9 +88,13 @@ type ServerConfig struct { // String returns the string representation of the ServerConfig. // -// Note that it covers (almost) all the fields so the string can be used map -// keys. Except NodeProto because NodeProto isn't used by federation (and this -// is only used as key in federation). +// This string representation will be used as map keys in federation +// (`map[ServerConfig]authority`), so that the xDS ClientConn and stream will be +// shared by authorities with different names but the same server config. +// +// It covers (almost) all the fields so the string can represent the config +// content. It doesn't cover NodeProto because NodeProto isn't used by +// federation. func (sc *ServerConfig) String() string { var ver string switch sc.TransportAPI {