Skip to content

Commit

Permalink
additional logging
Browse files Browse the repository at this point in the history
Signed-off-by: Scott Trent <[email protected]>
  • Loading branch information
trent-s committed Jun 6, 2024
1 parent 3234a54 commit 8126b2f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions internal/controller/labelgroup_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,11 +176,12 @@ func (r *LabelGroupReconciler) Reconcile(ctx context.Context, req ctrl.Request)
r.Logger.V(5).Info("[Reconcile] Entered aggregating case.") // trace
// Get list of pods matching the label group
podNames, namespaceNames, err := r.GetPodNamesMatchingLabels(ctx, labelGroup)
r.Logger.V(5).Info(fmt.Sprintf("[Reconcile-Aggregating] podNames: %s", podNames)) // trace
r.Logger.V(5).Info(fmt.Sprintf("[Reconcile-Aggregating] namespaceNames: %s", namespaceNames)) // trace
r.Logger.V(5).Info(fmt.Sprintf("[Reconcile] podNames: %s", podNames)) // trace
r.Logger.V(5).Info(fmt.Sprintf("[Reconcile] namespaceNames: %s", namespaceNames)) // trace

if err != nil || len(podNames) == 0 || len(namespaceNames) == 0 {
r.Logger.V(0).Error(err, "[Reconcile] Couldn't get pods for the labels provided.")
r.Logger.V(5).Info(fmt.Sprintf("[Reconcile] labelGroup: %#v", labelGroup)) // trace
return ctrl.Result{}, err
}

Expand Down

0 comments on commit 8126b2f

Please sign in to comment.