@@ -273,6 +273,7 @@ func (optr *Operator) syncStatus(ctx context.Context, original, config *configv1
273273 Message : fmt .Sprintf ("Error while reconciling %s: %s" , version , msg ),
274274 LastTransitionTime : now ,
275275 })
276+ klog .Infof ("!!!! %s" , fmt .Sprintf ("Error while reconciling %s: %s" , version , msg ))
276277 } else {
277278 resourcemerge .SetOperatorStatusCondition (& config .Status .Conditions , configv1.ClusterOperatorStatusCondition {
278279 Type : configv1 .OperatorProgressing ,
@@ -281,6 +282,7 @@ func (optr *Operator) syncStatus(ctx context.Context, original, config *configv1
281282 Message : fmt .Sprintf ("Unable to apply %s: %s" , version , msg ),
282283 LastTransitionTime : now ,
283284 })
285+ klog .Infof ("!!!! %s" , fmt .Sprintf ("Unable to apply %s: %s" , version , msg ))
284286 }
285287
286288 } else {
@@ -331,6 +333,7 @@ func (optr *Operator) syncStatus(ctx context.Context, original, config *configv1
331333 Message : message ,
332334 LastTransitionTime : now ,
333335 })
336+ klog .Infof ("!!!! %s" , message )
334337 }
335338 }
336339
@@ -357,33 +360,44 @@ func (optr *Operator) syncStatus(ctx context.Context, original, config *configv1
357360// its last update to go ready, or an hour has elapsed since the update began, before the condition is ignored.
358361func convertErrorToProgressing (history []configv1.UpdateHistory , now time.Time , status * SyncWorkerStatus ) (reason string , message string , ok bool ) {
359362 if len (history ) == 0 || status .Failure == nil || status .Reconciling {
363+ klog .Infof ("!!!! 1" )
360364 return "" , "" , false
361365 }
362366 uErr , ok := status .Failure .(* payload.UpdateError )
363367 if ! ok {
368+ klog .Infof ("!!!! 2" )
364369 return "" , "" , false
365370 }
366371 if uErr .Reason == "ClusterOperatorNotAvailable" || uErr .Reason == "ClusterOperatorsNotAvailable" {
367372 switch uErr .UpdateEffect {
368373 case payload .UpdateEffectNone :
374+ klog .Infof ("!!!! 3" )
369375 return uErr .Reason , fmt .Sprintf ("waiting on %s" , uErr .Name ), true
370376 case payload .UpdateEffectFail :
377+ klog .Infof ("!!!! 4" )
371378 return "" , "" , false
372379 case payload .UpdateEffectFailAfterInterval :
373380 var exceeded []string
374- threshold := now .Add (- (40 * time .Minute ))
381+ //threshold := now.Add(-(40 * time.Minute))
382+ threshold := now .Add (- (20 * time .Minute ))
375383 for _ , name := range strings .Split (uErr .Name , ", " ) {
376384 if payload .COUpdateStartTimesGet (name ).Before (threshold ) {
385+ klog .Infof ("!!!! exceeded=%s" , name )
377386 exceeded = append (exceeded , name )
378387 }
379388 }
380389 if len (exceeded ) > 0 {
381- return uErr .Reason , fmt .Sprintf ("wait has exceeded 40 minutes for these operators: %s" , strings .Join (exceeded , ", " )), false
390+ klog .Infof ("!!!! 5" )
391+ //return uErr.Reason, fmt.Sprintf("wait has exceeded 40 minutes for these operators: %s", strings.Join(exceeded, ", ")), false
392+ return uErr .Reason , fmt .Sprintf ("wait has exceeded 20 minutes for these operators: %s" , strings .Join (exceeded , ", " )), false
382393 } else {
383- return uErr .Reason , fmt .Sprintf ("waiting up to 40 minutes on %s" , uErr .Name ), true
394+ klog .Infof ("!!!! 6" )
395+ //return uErr.Reason, fmt.Sprintf("waiting up to 40 minutes on %s", uErr.Name), true
396+ return uErr .Reason , fmt .Sprintf ("waiting up to 20 minutes on %s" , uErr .Name ), true
384397 }
385398 }
386399 }
400+ klog .Infof ("!!!! 7" )
387401 return "" , "" , false
388402}
389403
0 commit comments