clusterx

package
v0.0.0-...-afb9292 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 31, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClusterSeparator   = "/"
	DefaultClusterName = "default"
)
View Source
const (
	OwnerNameKey      = "owner.name"
	OwnerNamespaceKey = "owner.namespace"
	OwnerClusterKey   = "owner.cluster"
)
View Source
const ClusterNameKey = "cluster.name"

Variables

This section is empty.

Functions

func GetClusterName

func GetClusterName(obj metav1.Object) string

func GetClusterNameNs

func GetClusterNameNs(ns string) (clusterName, namespace string)

func GetOwnerClusterName

func GetOwnerClusterName(sub metav1.Object) string

func GetOwnerNameNs

func GetOwnerNameNs(sub metav1.Object) types.NamespacedName

func MultiClustersEnqueue

func MultiClustersEnqueue(clusterName string) handler.EventHandler

func SetClusterName

func SetClusterName(obj metav1.Object, cluster string)

func SetOwner

func SetOwner(owner, sub metav1.Object)

Types

type MultiClusterClient

type MultiClusterClient struct {
	// contains filtered or unexported fields
}

func (MultiClusterClient) GetClient

func (mc MultiClusterClient) GetClient(name string) client.Client

GetClient by cluster name

func (MultiClusterClient) GetClientByNs

func (mc MultiClusterClient) GetClientByNs(ns string) client.Client

func (MultiClusterClient) GetClientByObj

func (mc MultiClusterClient) GetClientByObj(obj client.Object) client.Client

func (MultiClusterClient) GetOwnerClient

func (mc MultiClusterClient) GetOwnerClient(obj client.Object) client.Client

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL