Documentation ¶
Overview ¶
Package usage manages the lifecycle of usageResource objects.
Index ¶
- func RespectOwnerRefs() xpresource.ApplyOption
- func Setup(mgr ctrl.Manager, o apiextensionscontroller.Options) error
- type Reconciler
- type ReconcilerOption
- func WithClientApplicator(c xpresource.ClientApplicator) ReconcilerOption
- func WithFinalizer(f xpresource.Finalizer) ReconcilerOption
- func WithLogger(log logging.Logger) ReconcilerOption
- func WithPollInterval(after time.Duration) ReconcilerOption
- func WithRecorder(er event.Recorder) ReconcilerOption
- func WithSelectorResolver(sr selectorResolver) ReconcilerOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RespectOwnerRefs ¶
func RespectOwnerRefs() xpresource.ApplyOption
RespectOwnerRefs is an ApplyOption that ensures the existing owner references of the current Usage are respected. We need this option to be consumed in the composite controller since otherwise we lose the owner reference this controller puts on the Usage.
Types ¶
type Reconciler ¶
type Reconciler struct {
// contains filtered or unexported fields
}
A Reconciler reconciles Usages.
func NewReconciler ¶
func NewReconciler(mgr manager.Manager, opts ...ReconcilerOption) *Reconciler
NewReconciler returns a Reconciler of Usages.
type ReconcilerOption ¶
type ReconcilerOption func(*Reconciler)
ReconcilerOption is used to configure the Reconciler.
func WithClientApplicator ¶
func WithClientApplicator(c xpresource.ClientApplicator) ReconcilerOption
WithClientApplicator specifies how the Reconciler should interact with the Kubernetes API.
func WithFinalizer ¶
func WithFinalizer(f xpresource.Finalizer) ReconcilerOption
WithFinalizer specifies how the Reconciler should add and remove finalizers to and from the managed resource.
func WithLogger ¶
func WithLogger(log logging.Logger) ReconcilerOption
WithLogger specifies how the Reconciler should log messages.
func WithPollInterval ¶
func WithPollInterval(after time.Duration) ReconcilerOption
WithPollInterval specifies how long the Reconciler should wait before queueing a new reconciliation after a successful reconcile. The Reconciler requeues after a specified duration when it is not actively waiting for an external operation, but wishes to check whether resources it does not have a watch on (i.e. used/using resources) need to be reconciled.
func WithRecorder ¶
func WithRecorder(er event.Recorder) ReconcilerOption
WithRecorder specifies how the Reconciler should record Kubernetes events.
func WithSelectorResolver ¶
func WithSelectorResolver(sr selectorResolver) ReconcilerOption
WithSelectorResolver specifies how the Reconciler should resolve any resource references it encounters while reconciling Usages.