kubernetesk8s.io/kubernetes/pkg/volume/util/recyclerclient Index | Files

package recyclerclient

import "k8s.io/kubernetes/pkg/volume/util/recyclerclient"

Index

Functions

func RecycleVolumeByWatchingPodUntilCompletion

func RecycleVolumeByWatchingPodUntilCompletion(pvName string, pod *v1.Pod, kubeClient clientset.Interface, recorder RecycleEventRecorder) error

RecycleVolumeByWatchingPodUntilCompletion is intended for use with volume Recyclers. This function will save the given Pod to the API and watch it until it completes, fails, or the pod's ActiveDeadlineSeconds is exceeded, whichever comes first. An attempt to delete a recycler pod is always attempted before returning.

In case there is a pod with the same namespace+name already running, this function deletes it as it is not able to judge if it is an old recycler or user has forged a fake recycler to block Kubernetes from recycling.//

 pod - the pod designed by a volume plugin to recycle the volume. pod.Name
       will be overwritten with unique name based on PV.Name.
	client - kube client for API operations.

Types

type RecycleEventRecorder

type RecycleEventRecorder func(eventtype, message string)

RecycleEventRecorder is a func that defines how to record RecycleEvent.

Source Files

recycler_client.go

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

Tools for package owners.