mirror of https://github.com/grpc/grpc-go.git
cleanup: remove unused constants in generic xdsclient (#8315)
This commit is contained in:
parent
e3f13e75a6
commit
09166b665e
|
@ -51,19 +51,11 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// NameForServer represents the value to be passed as name when creating an xDS
|
|
||||||
// client from xDS-enabled gRPC servers. This is a well-known dedicated key
|
|
||||||
// value, and is defined in gRFC A71.
|
|
||||||
NameForServer = "#server"
|
|
||||||
|
|
||||||
defaultWatchExpiryTimeout = 15 * time.Second
|
defaultWatchExpiryTimeout = 15 * time.Second
|
||||||
name = "xds-client"
|
name = "xds-client"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
// ErrClientClosed is returned when the xDS client is closed.
|
|
||||||
ErrClientClosed = errors.New("xds: the xDS client is closed")
|
|
||||||
|
|
||||||
defaultExponentialBackoff = backoff.DefaultExponential.Backoff
|
defaultExponentialBackoff = backoff.DefaultExponential.Backoff
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -221,7 +213,7 @@ func (c *XDSClient) Close() {
|
||||||
// A non-nil error is returned if an xdsChannel was not created.
|
// A non-nil error is returned if an xdsChannel was not created.
|
||||||
func (c *XDSClient) getChannelForADS(serverConfig *ServerConfig, callingAuthority *authority) (*xdsChannel, func(), error) {
|
func (c *XDSClient) getChannelForADS(serverConfig *ServerConfig, callingAuthority *authority) (*xdsChannel, func(), error) {
|
||||||
if c.done.HasFired() {
|
if c.done.HasFired() {
|
||||||
return nil, nil, ErrClientClosed
|
return nil, nil, errors.New("xds: the xDS client is closed")
|
||||||
}
|
}
|
||||||
|
|
||||||
initLocked := func(s *channelState) {
|
initLocked := func(s *channelState) {
|
||||||
|
|
Loading…
Reference in New Issue