package
1.9.2
Repository: https://github.com/kubevela/pkg.git
Documentation: pkg.go.dev

# Functions

AddClusterGatewayClientFlags add flags for default cluster-gateway client.
AddFlags add flags for multicluster.
AddRemoteClusterClientFlags add flags for remote cluster client.
ClusterFrom returns the value of the cluster key on the ctx.
IsLocal check if cluster is local cluster.
NewClient create a multi-cluster client for handling multi-cluster requests If ClusterGatewayURL is not set, the client will use the Kubernetes aggregated api directly.
NewDefaultClient create default client with default DefaultClusterGatewayClientOptions.
NewNoConversionParamCodec create a empty ParameterCodec.
NewRemoteClusterClient create a client that will use separate RESTMappers for remote cluster requests.
NewTransport create a transport instance for handling multi-cluster request.
NewTransportWrapper create a WrapperFunc for wrapping RoundTripper with multi-cluster transport.
WithCluster returns a copy of parent in which the cluster value is set.

# Constants

Local is the name of the local cluster in KubeVela.

# Variables

DefaultClusterGatewayClientOptions the default ClusterGatewayClientOptions.
DefaultDisableRemoteClusterClient whether to disable RemoteClusterClient for default multicluster client.
RemoteClusterClientCachePruneProbability the cache prune probability of remote clusters' RESTMapper.
RemoteClusterClientCacheTimeout the timeout of remote cluster's RESTMapper cache.

# Structs

ClientOptions the options for creating multi-cluster gatedClient.
ClusterGatewayClientOptions the options for creating the gateway client.
Transport the transport for multi-cluster request.

# Interfaces

TransportOption option for creating transport.

# Type aliases

ForCluster create transport for specified cluster.