Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MultiClusterReconcileFunc ¶
type MultiClusterReconcileFunc func(id ezkube.ClusterResourceId) (bool, error)
reconcile a resource across multiple clusters. the passed resource can either be a ref to a resource (caused by a deletion), or an actual resource itself. ClusterName will always be set on the object.
type MultiClusterReconciler ¶ added in v0.8.0
type MultiClusterReconciler interface {
// reconcile the generic resource type.
// this function is called from generated code.
ReconcileClusterGeneric(id ezkube.ClusterResourceId) (reconcile.Result, error)
}
the MultiClusterReconciler reconciles events for input resources across clusters
func NewMultiClusterReconcilerImpl ¶ added in v0.8.0
func NewMultiClusterReconcilerImpl(
ctx context.Context,
reconcileFunc MultiClusterReconcileFunc,
reconcileInterval time.Duration,
) MultiClusterReconciler
Note(ilackarms): in the current implementation, the constructor also starts the reconciler's event processor in a goroutine. Make sure to cancel the parent context in order to ensure the goroutine started here is gc'ed. only one event will be processed per reconcileInterval.
type SingleClusterReconcileFunc ¶
type SingleClusterReconcileFunc func(id ezkube.ResourceId) (bool, error)
reconcile a resource in a single cluster. the passed resource can either be a ref to a resource (caused by a deletion), or an actual resource itself.
type SingleClusterReconciler ¶ added in v0.8.0
type SingleClusterReconciler interface {
// reconcile the generic resource type.
// this function is called from generated code.
ReconcileGeneric(id ezkube.ResourceId) (reconcile.Result, error)
}
the SingleClusterReconciler reconciles events for input resources in a single cluster
func NewSingleClusterReconciler ¶ added in v0.8.0
func NewSingleClusterReconciler(
ctx context.Context,
reconcileFunc SingleClusterReconcileFunc,
reconcileInterval time.Duration,
) SingleClusterReconciler
Note(ilackarms): in the current implementation, the constructor also starts the reconciler's event processor in a goroutine. Make sure to cancel the parent context in order to ensure the goroutine started here is gc'ed. only one event will be processed per reconcileInterval.