kubequota

package
v0.26.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const PluginName = "KCPKubeResourceQuota"

PluginName is the name of this admission plugin.

Variables

This section is empty.

Functions

func Register

func Register(plugins *admission.Plugins)

Register registers this admission plugin.

Types

type KubeResourceQuota

type KubeResourceQuota struct {
	*admission.Handler
	// contains filtered or unexported fields
}

KubeResourceQuota is an admission plugin that handles quota per logical cluster.

func NewKubeResourceQuota

func NewKubeResourceQuota(config *resourcequotaapi.Configuration) *KubeResourceQuota

NewKubeResourceQuota returns a new KubeResourceQuota admission plugin.

func (*KubeResourceQuota) SetExternalKubeInformerFactory

func (k *KubeResourceQuota) SetExternalKubeInformerFactory(informers informers.SharedInformerFactory)

func (*KubeResourceQuota) SetKcpInformers

func (k *KubeResourceQuota) SetKcpInformers(local, global kcpinformers.SharedInformerFactory)

func (*KubeResourceQuota) SetKubeClusterClient

func (k *KubeResourceQuota) SetKubeClusterClient(kubeClusterClient kcpkubernetesclientset.ClusterInterface)

func (*KubeResourceQuota) SetQuotaConfiguration

func (k *KubeResourceQuota) SetQuotaConfiguration(quotaConfiguration quota.Configuration)

func (*KubeResourceQuota) SetServerShutdownChannel

func (k *KubeResourceQuota) SetServerShutdownChannel(ch <-chan struct{})

func (*KubeResourceQuota) Validate

Validate gets or creates a resourcequota.QuotaAdmission plugin for the logical cluster in the request and then delegates validation to it.

func (*KubeResourceQuota) ValidateInitialization

func (k *KubeResourceQuota) ValidateInitialization() error

ValidateInitialization validates all the expected fields are set.

type LogicalClusterDeletionMonitor added in v0.20.0

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

LogicalClusterDeletionMonitor monitors LogicalClusters and invokes stopFunc for each deleted LogicalCluster.

func NewLogicalClusterDeletionMonitor added in v0.20.0

func NewLogicalClusterDeletionMonitor(
	name string,
	logicalClusterInformer corev1alpha1informers.LogicalClusterClusterInformer,
	stopFunc func(logicalcluster.Name),
) *LogicalClusterDeletionMonitor

func (*LogicalClusterDeletionMonitor) Start added in v0.20.0

func (m *LogicalClusterDeletionMonitor) Start(stop <-chan struct{})

Jump to

Keyboard shortcuts

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