Versions in this module Expand all Collapse all v1 v1.0.1 Nov 28, 2023 Changes in this version + const SyncTypeCreateOrPatch + const SyncTypeCreateOrUpdate + const SyncTypeFoundToPatch + const SyncTypeFoundToUpdate + var ErrIgnore = fmt.Errorf("ignored error") + var ErrOwnerDeleted = fmt.Errorf("owner is deleted") + func EventReason(obj client.Object, err error) string + type ObjectSyncer struct + Client client.Client + Ctx context.Context + MutateFn controllerutil.MutateFn + Obj client.Object + Owner client.Object + SyncType SyncType + func (s *ObjectSyncer) ObjectOwner() runtime.Object + func (s *ObjectSyncer) Sync(ctx context.Context) (SyncResult, error) + type SyncResult struct + EventMessage string + EventReason string + EventType string + Operation controllerutil.OperationResult + func (r *SyncResult) SetEventData(eventType, reason, message string) + type SyncType string + type Syncer interface + ObjectOwner func() runtime.Object + Sync func(context.Context) (SyncResult, error) + func NewObjectSyncer(ctx context.Context, client client.Client, owner client.Object, ...) Syncer