resources

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsClaimed

func IsClaimed(logger klog.Logger, selector kubebindv1alpha2.Selector, obj *unstructured.Unstructured, potentiallyReferencedResources *unstructured.UnstructuredList, isolation kubebindv1alpha2.Isolation) bool

IsClaimed returns true if the given object matches the given selector and named resources. Logger here is already at V(4) level.

func IsClaimedWithReference

func IsClaimedWithReference(
	logger klog.Logger,
	obj *unstructured.Unstructured,
	consumerSide bool,
	claim kubebindv1alpha2.PermissionClaim,
	apiServiceExport *kubebindv1alpha2.APIServiceExport,
	consumerClient dynamicclient.Interface,
	serviceNamespaceLister ServiceNamespaceLister,
) bool

IsClaimedWithReference returns true if the given object is claimed by the given permission claim. It handles both consumer side (no namespace remapping) and provider side (namespace remapping via APIServiceNamespace). The function fetches potentially referenced resources if a reference selector is present.

Types

type ServiceNamespaceLister

type ServiceNamespaceLister interface {
	List(selector labels.Selector) ([]*kubebindv1alpha2.APIServiceNamespace, error)
}

ServiceNamespaceLister is an interface for listing APIServiceNamespaces

Jump to

Keyboard shortcuts

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