cluster

package
v0.0.0-...-e809054 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cluster

type Cluster struct {
	*commoncluster.Config
	Client     runtimeclient.Client
	RESTClient *rest.RESTClient
	Cache      cache.Cache
}

func LookupMember

func LookupMember(ctx context.Context, memberClusters map[string]Cluster, namespacedName types.NamespacedName, object runtimeclient.Object) (Cluster, bool, error)

LookupMember takes in a list of member clusters and the NamespacedName of the Object, it then searches for the member cluster that triggered the request. returns memberCluster/true/nil in case the Object was found on one of the given member clusters returns memberCluster/true/error in case the Object was found on one of the given member clusters but there was also an error while searching it returns memberCluster/false/nil in case the Object was NOT found on any of the given member clusters returns memberCluster/false/error in case the Object was NOT found on any of the given member clusters and there was an error while trying to read one or more of the memberclusters

CAVEAT: if the object was not found and there is an error reading from more than one member cluster, only the last read error will be returned.

Jump to

Keyboard shortcuts

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