From 271642746080355826c55beaf4c9806defe1b4fd Mon Sep 17 00:00:00 2001 From: Jon Huhn Date: Tue, 29 Aug 2023 10:06:23 -0500 Subject: [PATCH] fixup! :seedling: check resource blocking clusterctl move during discovery --- cmd/clusterctl/client/cluster/mover.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/cmd/clusterctl/client/cluster/mover.go b/cmd/clusterctl/client/cluster/mover.go index 92e9087d784d..870687999d49 100644 --- a/cmd/clusterctl/client/cluster/mover.go +++ b/cmd/clusterctl/client/cluster/mover.go @@ -623,7 +623,15 @@ func waitReadyForMove(ctx context.Context, proxy Proxy, nodes []*node, dryRun bo } for _, n := range nodes { + log := log.WithValues( + "apiVersion", n.identity.GroupVersionKind(), + "resource", klog.ObjectRef{ + Name: n.identity.Name, + Namespace: n.identity.Namespace, + }, + ) if !n.blockingMove { + log.V(5).Info("Resource not blocking move") continue } @@ -638,7 +646,6 @@ func waitReadyForMove(ctx context.Context, proxy Proxy, nodes []*node, dryRun bo }, } key := client.ObjectKeyFromObject(obj) - log := log.WithValues("apiVersion", obj.GroupVersionKind(), "resource", klog.KObj(obj)) blockLogged := false if err := retryWithExponentialBackoff(backoff, func() error {