Skip to content

Commit 0bff380

Browse files
fix(load-balancer): don't print entire node object when adding robot target (#904)
When adding new targets to a loadbalancer, hcloud-cloud-controller-manager usually prints something along the lines add target op="hcops/LoadBalancerOps.ReconcileHCLBTargets" service="<service_name>" targetName="<node_name>" When adding robot nodes, it instead prints add target op="hcops/LoadBalancerOps.ReconcileHCLBTargets" service="<service_name>" targetName="<the entire serialized node object>" which is quite obviously wrong. This PR fixes so that it is only the name that is printed. I also changed to log message to communicate that this it is a robot node that is being added.
1 parent 0a43bac commit 0bff380

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

internal/hcops/load_balancer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -818,7 +818,7 @@ func (l *LoadBalancerOps) ReconcileHCLBTargets(
818818
continue
819819
}
820820

821-
klog.InfoS("add target", "op", op, "service", svc.ObjectMeta.Name, "targetName", node, "ip", ip)
821+
klog.InfoS("add target (robot node)", "op", op, "service", svc.ObjectMeta.Name, "targetName", node.Name, "ip", ip)
822822
opts := hcloud.LoadBalancerAddIPTargetOpts{
823823
IP: net.ParseIP(ip),
824824
}

0 commit comments

Comments
 (0)