api

package
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Conductor

type Conductor[Parent client.Object] interface {
	// Register takes a reconciler and registers it with the director
	Register(reconciler Reconciler[Parent]) Conductor[Parent]
	// Conduct takes the parent object and invokes the reconcilers registered with the director
	Conduct(ctx context.Context, parent Parent) (reconcile.Result, error)
	// Reconcile takes a single reconciler and invokes its Reconcile method, providing the necessary dependencies.
	Reconcile(ctx context.Context, reconciler Reconciler[Parent]) (reconcile.Result, error)
}

Conductor is an interface to simplify registration, execution and management of reconcilers

type Descriptor

type Descriptor struct {
	Name        string
	Description string
}

type Reconciler

type Reconciler[Parent client.Object] interface {
	Reconcile(ctx context.Context, client client.Client, parent Parent) (reconcile.Result, error)
	Describe() Descriptor
}

Jump to

Keyboard shortcuts

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