Skip to content

Commit 67bd868

Browse files
authored
revert: verbose logging (#64)
1 parent 134bbbc commit 67bd868

File tree

2 files changed

+0
-6
lines changed

2 files changed

+0
-6
lines changed

pkg/controller/node/node_controller.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ import (
2727
"sigs.k8s.io/controller-runtime/pkg/controller"
2828
"sigs.k8s.io/controller-runtime/pkg/event"
2929
"sigs.k8s.io/controller-runtime/pkg/handler"
30-
logf "sigs.k8s.io/controller-runtime/pkg/log"
3130
"sigs.k8s.io/controller-runtime/pkg/manager"
3231
"sigs.k8s.io/controller-runtime/pkg/reconcile"
3332
"sigs.k8s.io/controller-runtime/pkg/source"
@@ -83,12 +82,10 @@ func (e *podEnqueue) Generic(_ context.Context, _ event.TypedGenericEvent[*corev
8382
// canAddToQueue check if the Pod is associated to a node and is a daemonset pod
8483
func (e *podEnqueue) canAddToQueue(pod *corev1.Pod) bool {
8584
if pod.Spec.NodeName == "" {
86-
logf.Log.Info("cannot add pod to queue; node name is empty", "pod", pod.Name)
8785
return false
8886
}
8987
owner := v1.GetControllerOf(pod)
9088
if owner == nil {
91-
logf.Log.Info("cannot add pod to queue; owner is nil", "pod", pod.Name)
9289
return false
9390
}
9491
return owner.Kind == "DaemonSet"

pkg/nidhogg/handler.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,6 @@ func NewHandler(c client.Client, r record.EventRecorder, conf HandlerConfig) *Ha
110110
func (h *Handler) HandleNode(ctx context.Context, request reconcile.Request) (reconcile.Result, error) {
111111
log := logf.Log.WithName("nidhogg")
112112

113-
log.Info("begining handling of node", "node", request.NamespacedName)
114-
115113
// Fetch the Node instance
116114
latestNode := &corev1.Node{}
117115
err := h.Get(ctx, request.NamespacedName, latestNode)
@@ -297,7 +295,6 @@ func podReady(pod *corev1.Pod) bool {
297295
return condition.Status == corev1.ConditionTrue
298296
}
299297
}
300-
logf.Log.Info("pod is not ready", "pod", pod.Name, "condition", pod.Status.Conditions)
301298
return false
302299
}
303300

0 commit comments

Comments
 (0)