@@ -315,8 +315,8 @@ type UpdateConfig struct {
315315 ResourceContextControl resourcecontexts.ResourceContextControl
316316 Recorder record.EventRecorder
317317
318- scaleInLifecycleAdapter api.LifecycleAdapter
319- updateLifecycleAdapter api.LifecycleAdapter
318+ ScaleInLifecycleAdapter api.LifecycleAdapter
319+ UpdateLifecycleAdapter api.LifecycleAdapter
320320
321321 CacheExpectations expectations.CacheExpectationsInterface
322322 TargetGVK schema.GroupVersionKind
@@ -392,7 +392,7 @@ func (u *GenericTargetUpdater) BeginUpdateTarget(ctx context.Context, syncContex
392392 targetInfo := <- targetCh
393393 u .Recorder .Eventf (targetInfo .Object , corev1 .EventTypeNormal , "TargetUpdateLifecycle" , "try to begin TargetOpsLifecycle for updating Target of XSet" )
394394
395- if updated , err := opslifecycle .BeginWithCleaningOld (ctx , u .XsetLabelAnnoMgr , u .Client , u .updateLifecycleAdapter , targetInfo .Object , func (obj client.Object ) (bool , error ) {
395+ if updated , err := opslifecycle .BeginWithCleaningOld (ctx , u .XsetLabelAnnoMgr , u .Client , u .UpdateLifecycleAdapter , targetInfo .Object , func (obj client.Object ) (bool , error ) {
396396 if ! targetInfo .OnlyMetadataChanged && ! targetInfo .InPlaceUpdateSupport {
397397 return opslifecycle .WhenBeginDelete (u .XsetLabelAnnoMgr , obj )
398398 }
@@ -489,11 +489,11 @@ func (u *GenericTargetUpdater) FilterAllowOpsTargets(ctx context.Context, candid
489489func (u * GenericTargetUpdater ) FinishUpdateTarget (ctx context.Context , targetInfo * TargetUpdateInfo , finishByCancelUpdate bool ) error {
490490 if finishByCancelUpdate {
491491 // cancel update lifecycle
492- return opslifecycle .CancelOpsLifecycle (ctx , u .XsetLabelAnnoMgr , u .Client , u .updateLifecycleAdapter , targetInfo .Object )
492+ return opslifecycle .CancelOpsLifecycle (ctx , u .XsetLabelAnnoMgr , u .Client , u .UpdateLifecycleAdapter , targetInfo .Object )
493493 }
494494
495495 // target is ops finished, finish the lifecycle gracefully
496- if updated , err := opslifecycle .Finish (ctx , u .XsetLabelAnnoMgr , u .Client , u .updateLifecycleAdapter , targetInfo .Object ); err != nil {
496+ if updated , err := opslifecycle .Finish (ctx , u .XsetLabelAnnoMgr , u .Client , u .UpdateLifecycleAdapter , targetInfo .Object ); err != nil {
497497 return fmt .Errorf ("failed to finish TargetOpsLifecycle for updating Target %s/%s: %w" , targetInfo .GetNamespace (), targetInfo .GetName (), err )
498498 } else if updated {
499499 // add an expectation for this target update, before next reconciling
0 commit comments