finalizercontroller

package
v0.13.1 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2024 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAddFinalizerController

func NewAddFinalizerController(
	recorder events.Recorder,
	manifestWorkClient workv1client.ManifestWorkInterface,
	manifestWorkInformer workinformer.ManifestWorkInformer,
	manifestWorkLister worklister.ManifestWorkNamespaceLister,
) factory.Controller

NewAddFinalizerController returns a ManifestWorkController

func NewAppliedManifestWorkFinalizeController

func NewAppliedManifestWorkFinalizeController(
	recorder events.Recorder,
	spokeDynamicClient dynamic.Interface,
	appliedManifestWorkClient workv1client.AppliedManifestWorkInterface,
	appliedManifestWorkInformer workinformer.AppliedManifestWorkInformer,
	agentID string,
) factory.Controller

func NewManifestWorkFinalizeController

func NewManifestWorkFinalizeController(
	recorder events.Recorder,
	manifestWorkClient workv1client.ManifestWorkInterface,
	manifestWorkInformer workinformer.ManifestWorkInformer,
	manifestWorkLister worklister.ManifestWorkNamespaceLister,
	appliedManifestWorkClient workv1client.AppliedManifestWorkInterface,
	appliedManifestWorkInformer workinformer.AppliedManifestWorkInformer,
	hubHash string,
) factory.Controller

func NewUnManagedAppliedWorkController

func NewUnManagedAppliedWorkController(
	recorder events.Recorder,
	manifestWorkInformer workinformer.ManifestWorkInformer,
	manifestWorkLister worklister.ManifestWorkNamespaceLister,
	appliedManifestWorkClient workv1client.AppliedManifestWorkInterface,
	appliedManifestWorkInformer workinformer.AppliedManifestWorkInformer,
	evictionGracePeriod time.Duration,
	hubHash, agentID string,
) factory.Controller

NewUnManagedAppliedWorkController returns a controller to evict the unmanaged appliedmanifestworks.

An appliedmanifestwork will be considered unmanaged in the following scenarios:

  • the manifestwork of the current appliedmanifestwork is missing on the hub, or
  • the appliedmanifestwork hub hash does not match the current hub hash of the work agent.

One unmanaged appliedmanifestwork will be evicted from the managed cluster after a grace period (by default, 10 minutes), after one appliedmanifestwork is evicted from the managed cluster, its owned resources will also be evicted from the managed cluster with Kubernetes garbage collection.

Types

type AddFinalizerController

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

AddFinalizerController is to add the cluster.open-cluster-management.io/manifest-work-cleanup finalizer to manifestworks.

type AppliedManifestWorkFinalizeController

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

AppliedManifestWorkFinalizeController handles cleanup of appliedmanifestwork resources before deletion is allowed. It should handle all appliedmanifestworks belonging to this agent identified by the agentID.

type ManifestWorkFinalizeController

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

ManifestWorkFinalizeController handles cleanup of manifestwork resources before deletion is allowed.

Jump to

Keyboard shortcuts

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