Documentation
¶
Index ¶
Constants ¶
View Source
const ControllerName = "etcd-controller"
ControllerName is the name of the etcd controller.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reconciler ¶
type Reconciler struct {
// contains filtered or unexported fields
}
Reconciler reconciles the Etcd resource spec and status.
func NewReconciler ¶
func NewReconciler(mgr manager.Manager, config druidconfigv1alpha1.EtcdControllerConfiguration) (*Reconciler, error)
NewReconciler creates a new reconciler for Etcd.
func NewReconcilerWithImageVector ¶
func NewReconcilerWithImageVector(mgr manager.Manager, controllerName string, config druidconfigv1alpha1.EtcdControllerConfiguration, iv imagevector.ImageVector) (*Reconciler, error)
NewReconcilerWithImageVector creates a new reconciler for Etcd with the given image vector.
func (*Reconciler) GetOperatorRegistry ¶
func (r *Reconciler) GetOperatorRegistry() component.Registry
GetOperatorRegistry returns the component registry.
func (*Reconciler) Reconcile ¶
Reconcile manages the reconciliation of the Etcd component to align it with its desired specifications.
The reconciliation process involves the following steps:
- Deletion Handling: If the Etcd component has a deletionTimestamp, initiate the deletion workflow. On error, requeue the request.
- Spec Reconciliation : Determine whether the Etcd spec should be reconciled based on annotations and flags, and if there is a need then reconcile spec.
- Status Reconciliation: Always update the status of the Etcd component to reflect its current state, as well as status fields derived from spec reconciliation.
- Remove operation-reconcile annotation if it was set and if spec reconciliation had succeeded.
- Scheduled Requeue: Requeue the reconciliation request after a defined period (EtcdStatusSyncPeriod) to maintain sync.
func (*Reconciler) RegisterWithManager ¶
func (r *Reconciler) RegisterWithManager(mgr ctrl.Manager, controllerName string) error
RegisterWithManager registers the Etcd Controller with the given controller manager.
Click to show internal directories.
Click to hide internal directories.