Documentation
¶
Overview ¶
Package xds contains functions, structs, and utilities for working with handshake cluster names, as well as shared components used by xds balancers and resolvers. It is separated from the top-level /internal package to avoid circular dependencies.
Index ¶
- Variables
- func GetLocalityID(addr resolver.Address) clients.Locality
- func GetXDSHandshakeClusterName(attr *attributes.Attributes) (string, bool)
- func IsLocalityEqual(l clients.Locality, o any) bool
- func LocalityFromString(s string) (ret clients.Locality, _ error)
- func LocalityString(l clients.Locality) string
- func SetLocalityID(addr resolver.Address, l clients.Locality) resolver.Address
- func SetLocalityIDInEndpoint(endpoint resolver.Endpoint, l clients.Locality) resolver.Endpoint
- func SetXDSHandshakeClusterName(addr resolver.Address, clusterName string) resolver.Address
Constants ¶
This section is empty.
Variables ¶
var UnknownCSMLabels = map[string]string{
"csm.service_name": "unknown",
"csm.service_namespace_name": "unknown",
}
UnknownCSMLabels are TelemetryLabels emitted from CDS if CSM Telemetry Label data is not present in the CDS Resource.
Functions ¶
func GetLocalityID ¶ added in v1.76.0
GetLocalityID returns the locality ID of addr.
func GetXDSHandshakeClusterName ¶ added in v1.63.0
func GetXDSHandshakeClusterName(attr *attributes.Attributes) (string, bool)
GetXDSHandshakeClusterName returns cluster name stored in attr.
func IsLocalityEqual ¶ added in v1.76.0
IsLocalityEqual allows the values to be compared by Attributes.Equal.
func LocalityFromString ¶ added in v1.76.0
LocalityFromString converts a string representation of clients.locality as specified in gRFC A76, into a LocalityID struct.
func LocalityString ¶ added in v1.76.0
LocalityString generates a string representation of clients.Locality in the format specified in gRFC A76.
func SetLocalityID ¶ added in v1.76.0
SetLocalityID sets locality ID in addr to l.
func SetLocalityIDInEndpoint ¶ added in v1.76.0
SetLocalityIDInEndpoint sets locality ID in endpoint to l.
Types ¶
This section is empty.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package balancer installs all the xds balancers.
|
Package balancer installs all the xds balancers. |
|
cdsbalancer
Package cdsbalancer implements a balancer to handle CDS responses.
|
Package cdsbalancer implements a balancer to handle CDS responses. |
|
clusterimpl
Package clusterimpl implements the xds_cluster_impl balancing policy.
|
Package clusterimpl implements the xds_cluster_impl balancing policy. |
|
clustermanager
Package clustermanager implements the cluster manager LB policy for xds.
|
Package clustermanager implements the cluster manager LB policy for xds. |
|
clusterresolver
Package clusterresolver contains the implementation of the cluster_resolver_experimental LB policy which resolves endpoint addresses using a list of one or more discovery mechanisms.
|
Package clusterresolver contains the implementation of the cluster_resolver_experimental LB policy which resolves endpoint addresses using a list of one or more discovery mechanisms. |
|
loadstore
Package loadstore contains the loadStoreWrapper shared by the balancers.
|
Package loadstore contains the loadStoreWrapper shared by the balancers. |
|
outlierdetection
Package outlierdetection provides an implementation of the outlier detection LB policy, as defined in https://github.com/grpc/proposal/blob/master/A50-xds-outlier-detection.md.
|
Package outlierdetection provides an implementation of the outlier detection LB policy, as defined in https://github.com/grpc/proposal/blob/master/A50-xds-outlier-detection.md. |
|
priority
Package priority implements the priority balancer.
|
Package priority implements the priority balancer. |
|
wrrlocality
Package wrrlocality provides an implementation of the wrr locality LB policy, as defined in [A52 - xDS Custom LB Policies].
|
Package wrrlocality provides an implementation of the wrr locality LB policy, as defined in [A52 - xDS Custom LB Policies]. |
|
Package bootstrap provides the functionality to initialize certain aspects of an xDS client by reading a bootstrap file.
|
Package bootstrap provides the functionality to initialize certain aspects of an xDS client by reading a bootstrap file. |
|
jwtcreds
Package jwtcreds implements JWT CallCredentials for XDS, configured via xDS Bootstrap File.
|
Package jwtcreds implements JWT CallCredentials for XDS, configured via xDS Bootstrap File. |
|
tlscreds
Package tlscreds implements mTLS Credentials in xDS Bootstrap File.
|
Package tlscreds implements mTLS Credentials in xDS Bootstrap File. |
|
Package clients provides implementations of the clients to interact with xDS and LRS servers.
|
Package clients provides implementations of the clients to interact with xDS and LRS servers. |
|
grpctransport
Package grpctransport provides an implementation of the clients.TransportBuilder interface using gRPC.
|
Package grpctransport provides an implementation of the clients.TransportBuilder interface using gRPC. |
|
internal
Package internal contains helpers for xDS and LRS clients.
|
Package internal contains helpers for xDS and LRS clients. |
|
internal/backoff
Package backoff implements the backoff strategy for clients.
|
Package backoff implements the backoff strategy for clients. |
|
internal/buffer
Package buffer provides an implementation of an unbounded buffer.
|
Package buffer provides an implementation of an unbounded buffer. |
|
internal/pretty
Package pretty defines helper functions to pretty-print structs for logging.
|
Package pretty defines helper functions to pretty-print structs for logging. |
|
internal/syncutil
Package syncutil implements additional synchronization primitives built upon the sync package.
|
Package syncutil implements additional synchronization primitives built upon the sync package. |
|
internal/testutils
Package testutils contains testing helpers for xDS and LRS clients.
|
Package testutils contains testing helpers for xDS and LRS clients. |
|
internal/testutils/e2e
Package e2e provides utilities for end2end testing of xDS and LRS clients functionalities.
|
Package e2e provides utilities for end2end testing of xDS and LRS clients functionalities. |
|
internal/testutils/fakeserver
Package fakeserver provides a fake implementation of the management server.
|
Package fakeserver provides a fake implementation of the management server. |
|
lrsclient
Package lrsclient provides an LRS (Load Reporting Service) client.
|
Package lrsclient provides an LRS (Load Reporting Service) client. |
|
lrsclient/internal
Package internal contains functionality internal to the lrsclient package.
|
Package internal contains functionality internal to the lrsclient package. |
|
xdsclient
Package xdsclient provides an xDS (* Discovery Service) client.
|
Package xdsclient provides an xDS (* Discovery Service) client. |
|
xdsclient/internal
Package internal contains functionality internal to the xdsclient package.
|
Package internal contains functionality internal to the xdsclient package. |
|
xdsclient/internal/xdsresource
Package xdsresource defines constants to distinguish between supported xDS API versions.
|
Package xdsresource defines constants to distinguish between supported xDS API versions. |
|
xdsclient/metrics
Package metrics defines all metrics that can be produced by an xDS client.
|
Package metrics defines all metrics that can be produced by an xDS client. |
|
Package clusterspecifier contains the ClusterSpecifier interface and a registry for storing and retrieving their implementations.
|
Package clusterspecifier contains the ClusterSpecifier interface and a registry for storing and retrieving their implementations. |
|
rls
Package rls implements the RLS cluster specifier plugin.
|
Package rls implements the RLS cluster specifier plugin. |
|
Package httpfilter contains the HTTPFilter interface and a registry for storing and retrieving their implementations.
|
Package httpfilter contains the HTTPFilter interface and a registry for storing and retrieving their implementations. |
|
fault
Package fault implements the Envoy Fault Injection HTTP filter.
|
Package fault implements the Envoy Fault Injection HTTP filter. |
|
rbac
Package rbac implements the Envoy RBAC HTTP filter.
|
Package rbac implements the Envoy RBAC HTTP filter. |
|
router
Package router implements the Envoy Router HTTP filter.
|
Package router implements the Envoy Router HTTP filter. |
|
Package matcher contains types that need to be shared between code under google.golang.org/grpc/xds/...
|
Package matcher contains types that need to be shared between code under google.golang.org/grpc/xds/... |
|
Package rbac provides service-level and method-level access control for a service.
|
Package rbac provides service-level and method-level access control for a service. |
|
Package resolver implements the xds resolver, that does LDS and RDS to find the cluster to use.
|
Package resolver implements the xds resolver, that does LDS and RDS to find the cluster to use. |
|
internal
Package internal contains functionality internal to the xDS resolver.
|
Package internal contains functionality internal to the xDS resolver. |
|
Package server contains internal server-side functionality used by the public facing xds package.
|
Package server contains internal server-side functionality used by the public facing xds package. |
|
test
|
|
|
e2e
Package e2e implements xds e2e tests using go-control-plane.
|
Package e2e implements xds e2e tests using go-control-plane. |
|
Package testutils provides utility types, for use in xds tests.
|
Package testutils provides utility types, for use in xds tests. |
|
fakeclient
Package fakeclient provides a fake implementation of an xDS client.
|
Package fakeclient provides a fake implementation of an xDS client. |
|
Package xdsclient implements a full fledged gRPC client for the xDS API used by the xds resolver and balancer implementations.
|
Package xdsclient implements a full fledged gRPC client for the xDS API used by the xds resolver and balancer implementations. |
|
internal
Package internal contains functionality internal to the xdsclient package.
|
Package internal contains functionality internal to the xdsclient package. |
|
xdslbregistry
Package xdslbregistry provides a registry of converters that convert proto from load balancing configuration, defined by the xDS API spec, to JSON load balancing configuration.
|
Package xdslbregistry provides a registry of converters that convert proto from load balancing configuration, defined by the xDS API spec, to JSON load balancing configuration. |
|
xdslbregistry/converter
Package converter provides converters to convert proto load balancing configuration, defined by the xDS API spec, to JSON load balancing configuration.
|
Package converter provides converters to convert proto load balancing configuration, defined by the xDS API spec, to JSON load balancing configuration. |
|
xdsresource
Package xdsresource implements the xDS data model layer.
|
Package xdsresource implements the xDS data model layer. |
|
xdsresource/version
Package version defines constants to distinguish between supported xDS API versions.
|
Package version defines constants to distinguish between supported xDS API versions. |