xds: change ServerConfig
type to have a single method to return all configured dial options
#7661
Labels
Area: xDS
Includes everything xDS related, including LB policies used with xDS.
Type: Internal Cleanup
Refactors, etc
The
ServerConfig
type in internalbootstrap
package currently stores the credentials configured for the server config as a dial option here: https://github.com/grpc/grpc-go/blob/master/internal/xds/bootstrap/bootstrap.go#L177-L181 and it has a method to return the configured credentials as dial option here:grpc-go/internal/xds/bootstrap/bootstrap.go
Line 222 in 8ea3460
As part of #7586, we are adding more dial options to the server config, and the PR currently adds a new method to return the new dial option. Once that PR is merged, we should instead have a single method in the
ServerConfig
type that returns a slice of dial options.These dial options are usually retrieved from the
ServerConfig
when a transport to the corresponding server is being created. This is currently where it is being used:grpc-go/xds/internal/xdsclient/transport/transport.go
Line 197 in 8ea3460
ServerConfig
that returns all configured dial options.The text was updated successfully, but these errors were encountered: