kubernetesk8s.io/kubernetes/pkg/controller/namespace/deletion Index | Files

package deletion

import "k8s.io/kubernetes/pkg/controller/namespace/deletion"

Index

Types

type NamespaceConditionUpdater

type NamespaceConditionUpdater interface {
	ProcessDiscoverResourcesErr(e error)
	ProcessGroupVersionErr(e error)
	ProcessDeleteContentErr(e error)
	Update(*v1.Namespace) bool
}

NamespaceConditionUpdater interface that translates namespace deleter errors into namespace status conditions.

type NamespacedResourcesDeleterInterface

type NamespacedResourcesDeleterInterface interface {
	Delete(ctx context.Context, nsName string) error
}

NamespacedResourcesDeleterInterface is the interface to delete a namespace with all resources in it.

func NewNamespacedResourcesDeleter

func NewNamespacedResourcesDeleter(ctx context.Context, nsClient v1clientset.NamespaceInterface,
	metadataClient metadata.Interface, podsGetter v1clientset.PodsGetter,
	discoverResourcesFn func() ([]*metav1.APIResourceList, error),
	finalizerToken v1.FinalizerName) NamespacedResourcesDeleterInterface

NewNamespacedResourcesDeleter returns a new NamespacedResourcesDeleter.

type ResourcesRemainingError

type ResourcesRemainingError struct {
	Estimate int64
}

ResourcesRemainingError is used to inform the caller that all resources are not yet fully removed from the namespace.

func (*ResourcesRemainingError) Error

func (e *ResourcesRemainingError) Error() string

Source Files

namespaced_resources_deleter.go status_condition_utils.go

Version
v1.33.0 (latest)
Published
Apr 23, 2025
Platform
linux/amd64
Imports
20 packages
Last checked
3 hours ago

Tools for package owners.