reconciler

package
v1.39.3 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2022 License: Apache-2.0, BSD-2-Clause, MIT, + 1 more Imports: 7 Imported by: 23

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func OperationAnnotationWrapper

func OperationAnnotationWrapper(newObjFunc func() client.Object, reconciler reconcile.Reconciler) reconcile.Reconciler

OperationAnnotationWrapper is a wrapper for an reconciler that removes the Gardener operation annotation before `Reconcile` is called.

This is useful in conjunction with the HasOperationAnnotation predicate.

func ReconcileErr

func ReconcileErr(err error) (reconcile.Result, error)

ReconcileErr returns a reconcile.Result or an error, depending on whether the error is a RequeueAfterError or not.

func ReconcileErrCause

func ReconcileErrCause(err error) error

ReconcileErrCause returns the cause in case the error is an RequeueAfterError. Otherwise, it returns the input error.

func ReconcileErrCauseOrErr

func ReconcileErrCauseOrErr(err error) error

ReconcileErrCauseOrErr returns the cause of the error or the error if the cause is nil.

Types

type RequeueAfterError

type RequeueAfterError struct {
	// Cause is an optional cause that may be returned together with a time for requeueing.
	Cause error
	// RequeueAfter is the duration after which the request should be enqueued again.
	RequeueAfter time.Duration
}

RequeueAfterError is an error that indicates that an actuator wants a reconcile operation to be requeued again after RequeueAfter has passed.

func (*RequeueAfterError) Error

func (e *RequeueAfterError) Error() string

Jump to

Keyboard shortcuts

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