lifecyclehandler

package
v1.118.2 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CausedByUnreadyOrNonexistentResourceRefs added in v1.92.0

func CausedByUnreadyOrNonexistentResourceRefs(err error) (refGVK schema.GroupVersionKind, refNN types.NamespacedName, ok bool)

CausedByUnreadyOrNonexistentResourceRefs checks to see if the input error is related to an unready or non-existent resource reference. Note that KeyInSecretNotFoundError is not included in this list.

func CausedByUnresolvableDeps

func CausedByUnresolvableDeps(err error) (unwrappedErr error, ok bool)

func IsOrphaned

func IsOrphaned(resource *k8s.Resource, parentReferenceConfigs []corekccv1alpha1.TypeConfig, kubeClient client.Client) (orphaned bool, parent *k8s.Resource, err error)

Types

type LifecycleHandler

type LifecycleHandler struct {
	client.Client
	Recorder record.EventRecorder
	// contains filtered or unexported fields
}

The LifecycleHandler contains common methods to handle the lifecycle of the reconciliation

func NewLifecycleHandler added in v1.93.0

func NewLifecycleHandler(c client.Client, r record.EventRecorder) LifecycleHandler

func NewLifecycleHandlerWithFieldOwner added in v1.93.0

func NewLifecycleHandlerWithFieldOwner(c client.Client, r record.EventRecorder, fieldOwner string) LifecycleHandler

func (*LifecycleHandler) EnsureFinalizers

func (r *LifecycleHandler) EnsureFinalizers(ctx context.Context, original, resource *k8s.Resource, finalizers ...string) error

func (*LifecycleHandler) HandleDeleteFailed

func (r *LifecycleHandler) HandleDeleteFailed(ctx context.Context, resource *k8s.Resource, err error) error

func (*LifecycleHandler) HandleDeleted

func (r *LifecycleHandler) HandleDeleted(ctx context.Context, resource *k8s.Resource) error

func (*LifecycleHandler) HandleDeleting

func (r *LifecycleHandler) HandleDeleting(ctx context.Context, resource *k8s.Resource) error

func (*LifecycleHandler) HandleObtainLeaseFailed

func (r *LifecycleHandler) HandleObtainLeaseFailed(ctx context.Context, resource *k8s.Resource, err error) error

func (*LifecycleHandler) HandlePostActuationTransformFailed

func (r *LifecycleHandler) HandlePostActuationTransformFailed(ctx context.Context, resource *k8s.Resource, err error) error

func (*LifecycleHandler) HandlePreActuationTransformFailed

func (r *LifecycleHandler) HandlePreActuationTransformFailed(ctx context.Context, resource *k8s.Resource, err error) error

func (*LifecycleHandler) HandleUnmanaged added in v1.95.0

func (r *LifecycleHandler) HandleUnmanaged(ctx context.Context, resource *k8s.Resource) error

func (*LifecycleHandler) HandleUnresolvableDeps

func (r *LifecycleHandler) HandleUnresolvableDeps(ctx context.Context, resource *k8s.Resource, originErr error) error

func (*LifecycleHandler) HandleUpToDate

func (r *LifecycleHandler) HandleUpToDate(ctx context.Context, resource *k8s.Resource) error

func (*LifecycleHandler) HandleUpdateFailed

func (r *LifecycleHandler) HandleUpdateFailed(ctx context.Context, resource *k8s.Resource, err error) error

func (*LifecycleHandler) HandleUpdating

func (r *LifecycleHandler) HandleUpdating(ctx context.Context, resource *k8s.Resource) error

Jump to

Keyboard shortcuts

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