@@ -92,7 +92,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
9292 return r .removeAllWorks (ctx , placementOld )
9393 }
9494
95- klog .V (3 ).InfoS ("Successfully selected clusters" , "placement" , placementOld .Name , "number of clusters" , len (selectedClusters ))
95+ klog .V (2 ).InfoS ("Successfully selected clusters" , "placement" , placementOld .Name , "number of clusters" , len (selectedClusters ))
9696
9797 // select the new resources and record the result in the placementNew status
9898 manifests , scheduleErr := r .selectResources (ctx , placementNew )
@@ -107,7 +107,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
107107 klog .V (2 ).InfoS ("No resources match the placement" , "placement" , placeRef )
108108 return r .removeAllWorks (ctx , placementOld )
109109 }
110- klog .V (3 ).InfoS ("Successfully selected resources" , "placement" , placementOld .Name , "number of resources" , len (manifests ))
110+ klog .V (2 ).InfoS ("Successfully selected resources" , "placement" , placementOld .Name , "number of resources" , len (manifests ))
111111
112112 // persist union of the all the selected resources and clusters between placementNew and placementOld so that we won't
113113 // get orphaned resource/cluster if the reconcile loops stops between work creation and the placement status persisted
@@ -118,7 +118,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
118118 _ = r .Client .Status ().Update (ctx , placementOld , client .FieldOwner (utils .PlacementFieldManagerName ))
119119 return ctrl.Result {}, scheduleErr
120120 }
121- klog .V (3 ).InfoS ("Successfully persisted the intermediate scheduling result" , "placement" , placementOld .Name ,
121+ klog .V (2 ).InfoS ("Successfully persisted the intermediate scheduling result" , "placement" , placementOld .Name ,
122122 "totalClusters" , totalCluster , "totalResources" , totalResources )
123123 // pick up the new version so placementNew can continue to update
124124 placementNew .SetResourceVersion (placementOld .GetResourceVersion ())
@@ -131,7 +131,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
131131 _ = r .Client .Status ().Update (ctx , placementOld , client .FieldOwner (utils .PlacementFieldManagerName ))
132132 return ctrl.Result {}, scheduleErr
133133 }
134- klog .V (3 ).InfoS ("Successfully scheduled work resources" , "placement" , placementOld .Name , "number of clusters" , len (selectedClusters ))
134+ klog .V (2 ).InfoS ("Successfully scheduled work resources" , "placement" , placementOld .Name , "number of clusters" , len (selectedClusters ))
135135
136136 // go through the existing cluster list and remove work from no longer scheduled clusters.
137137 removed , scheduleErr := r .removeStaleWorks (ctx , placementNew .GetName (), placementOld .Status .TargetClusters , placementNew .Status .TargetClusters )
@@ -144,7 +144,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
144144 _ = r .Client .Status ().Update (ctx , placementOld , client .FieldOwner (utils .PlacementFieldManagerName ))
145145 return ctrl.Result {}, scheduleErr
146146 }
147- klog .V (3 ).InfoS ("Successfully removed work resources from previously selected clusters" , "placement" , placementOld .Name , "removed clusters" , removed )
147+ klog .V (2 ).InfoS ("Successfully removed work resources from previously selected clusters" , "placement" , placementOld .Name , "removed clusters" , removed )
148148
149149 // the schedule has succeeded, so we now can use the placementNew status that contains all the newly selected cluster and resources
150150 r .updatePlacementScheduledCondition (placementNew , nil )
@@ -157,7 +157,7 @@ func (r *Reconciler) Reconcile(ctx context.Context, key controller.QueueKey) (ct
157157 _ = r .Client .Status ().Update (ctx , placementNew , client .FieldOwner (utils .PlacementFieldManagerName ))
158158 return ctrl.Result {}, applyErr
159159 }
160- klog .V (3 ).InfoS ("Successfully collected work resources status from all selected clusters" ,
160+ klog .V (2 ).InfoS ("Successfully collected work resources status from all selected clusters" ,
161161 "placement" , placementOld .Name , "number of clusters" , len (selectedClusters ), "hasPending" , hasPending ,
162162 "numberFailedPlacement" , len (placementNew .Status .FailedResourcePlacements ))
163163
@@ -182,7 +182,7 @@ func (r *Reconciler) removeAllWorks(ctx context.Context, placement *fleetv1alpha
182182 klog .ErrorS (removeErr , "failed to remove all the work resources from previously selected clusters" , "placement" , placeRef )
183183 return ctrl.Result {}, removeErr
184184 }
185- klog .V (3 ).InfoS ("Successfully removed work resources from previously selected clusters" ,
185+ klog .V (2 ).InfoS ("Successfully removed work resources from previously selected clusters" ,
186186 "placement" , placeRef , "number of removed clusters" , removed )
187187 placement .Status .TargetClusters = nil
188188 placement .Status .SelectedResources = nil
@@ -262,7 +262,7 @@ func (r *Reconciler) updatePlacementScheduledCondition(placement *fleetv1alpha1.
262262 ObservedGeneration : placement .Generation ,
263263 })
264264 if schedCond == nil || schedCond .Status != metav1 .ConditionTrue {
265- klog .V (3 ).InfoS ("successfully scheduled all selected resources to their clusters" , "placement" , placementRef )
265+ klog .V (2 ).InfoS ("successfully scheduled all selected resources to their clusters" , "placement" , placementRef )
266266 r .Recorder .Event (placement , corev1 .EventTypeNormal , "ResourceScheduled" , "successfully scheduled all selected resources to their clusters" )
267267 }
268268 } else {
@@ -293,7 +293,7 @@ func (r *Reconciler) updatePlacementAppliedCondition(placement *fleetv1alpha1.Cl
293293 Message : "Successfully applied resources to member clusters" ,
294294 ObservedGeneration : placement .Generation ,
295295 })
296- klog .V (3 ).InfoS ("successfully applied all selected resources" , "placement" , placementRef )
296+ klog .V (2 ).InfoS ("successfully applied all selected resources" , "placement" , placementRef )
297297 if preAppliedCond == nil || preAppliedCond .Status != metav1 .ConditionTrue {
298298 r .Recorder .Event (placement , corev1 .EventTypeNormal , "ResourceApplied" , "successfully applied all selected resources" )
299299 }
@@ -305,7 +305,7 @@ func (r *Reconciler) updatePlacementAppliedCondition(placement *fleetv1alpha1.Cl
305305 Message : applyErr .Error (),
306306 ObservedGeneration : placement .Generation ,
307307 })
308- klog .V (3 ).InfoS ("Some selected resources are still waiting to be applied" , "placement" , placementRef )
308+ klog .V (2 ).InfoS ("Some selected resources are still waiting to be applied" , "placement" , placementRef )
309309 if preAppliedCond == nil || preAppliedCond .Status == metav1 .ConditionTrue {
310310 r .Recorder .Event (placement , corev1 .EventTypeWarning , "ResourceApplyPending" , "Some applied resources are now waiting to be applied to the member cluster" )
311311 }
@@ -318,7 +318,7 @@ func (r *Reconciler) updatePlacementAppliedCondition(placement *fleetv1alpha1.Cl
318318 Message : applyErr .Error (),
319319 ObservedGeneration : placement .Generation ,
320320 })
321- klog .V (3 ).InfoS ("failed to apply some selected resources" , "placement" , placementRef )
321+ klog .V (2 ).InfoS ("failed to apply some selected resources" , "placement" , placementRef )
322322 if preAppliedCond == nil || preAppliedCond .Status != metav1 .ConditionFalse {
323323 r .Recorder .Event (placement , corev1 .EventTypeWarning , "ResourceApplyFailed" , "failed to apply some selected resources" )
324324 }
0 commit comments