You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// TODO(maxcao13): Do we have to check the policy resource too? i.e. if only memory is getting scaled, then only check the memory resize policy?
469
469
for_, policy:=rangecontainer.ResizePolicy {
470
470
ifpolicy.RestartPolicy!=apiv1.NotRequired {
471
-
klog.Warningf("in-place resize of %s will cause container disruption, container %s restart policy is %v", pod.Name, container.Name, policy.RestartPolicy)
471
+
klog.InfoS("in-place resize of pod will cause container disruption, because of container resize policy", "pod", klog.KObj(pod), "container", container.Name, "restartPolicy", policy.RestartPolicy)
472
472
// TODO(jkyros): is there something that prevents this from happening elsewhere in the API?
klog.Warningf("in-place resize of %s not possible, container %s resize policy is %v but pod restartPolicy is %v", pod.Name, container.Name, policy.RestartPolicy, pod.Spec.RestartPolicy)
klog.V(4).InfoS(fmt.Sprintf("In-place update deferred for more than %v, falling back to eviction", DeferredResizeUpdateTimeout), "pod", pod.Name)
435
+
klog.V(4).InfoS(fmt.Sprintf("In-place update deferred for more than %v, falling back to eviction", DeferredResizeUpdateTimeout), "pod", klog.KObj(pod))
436
436
fallBackToEviction=true
437
437
} else {
438
-
klog.V(4).Infof("In-place update deferred for %s, NOT falling back to eviction yet", pod.Name)
438
+
klog.V(4).InfoS("In-place update deferred, NOT falling back to eviction yet", "pod", klog.KObj(pod))
klog.V(4).InfoS(fmt.Sprintf("In-place update in progress for more than %v, falling back to eviction", InProgressResizeUpdateTimeout), "pod", pod.Name)
442
+
klog.V(4).InfoS(fmt.Sprintf("In-place update in progress for more than %v, falling back to eviction", InProgressResizeUpdateTimeout), "pod", klog.KObj(pod))
443
443
fallBackToEviction=true
444
444
} else {
445
-
klog.V(4).InfoS("In-place update in progress, NOT falling back to eviction yet", "pod", pod.Name)
445
+
klog.V(4).InfoS("In-place update in progress, NOT falling back to eviction yet", "pod", klog.KObj(pod))
446
446
}
447
447
caseapiv1.PodResizeStatusInfeasible:
448
-
klog.V(4).InfoS("In-place update infeasible, falling back to eviction", "pod", pod.Name)
448
+
klog.V(4).InfoS("In-place update infeasible, falling back to eviction", "pod", klog.KObj(pod))
449
449
fallBackToEviction=true
450
450
default:
451
-
klog.V(4).InfoS("In-place update status unknown, falling back to eviction", "pod", pod.Name)
451
+
klog.V(4).InfoS("In-place update status unknown, falling back to eviction", "pod", klog.KObj(pod))
452
452
fallBackToEviction=true
453
453
}
454
454
return
@@ -458,15 +458,15 @@ func (u *updater) AttemptInPlaceScalingIfPossible(ctx context.Context, vpaSize i
458
458
err=u.evictionRateLimiter.Wait(ctx)
459
459
iferr!=nil {
460
460
// TODO(jkyros): whether or not we fall back to eviction here probably depends on *why* we failed
461
-
klog.Warningf("updating pod %v failed: %v", pod.Name, err)
461
+
klog.ErrorS(err, "updating pod failed", "pod", klog.KObj(pod))
462
462
return
463
463
}
464
464
465
-
klog.V(2).Infof("attempting to in-place update pod %v", pod.Name)
465
+
klog.V(2).InfoS("attempting to in-place update pod", "pod", klog.KObj(pod))
klog.V(4).Infof("Pod %s looks like it's stuck scaling up (%v state), leaving it in for eviction", pod.Name, pod.Status.Resize)
92
+
klog.V(4).InfoS("Pod looks like it's stuck scaling up, leaving it in for eviction", "pod", klog.KObj(pod), "resizeStatus", pod.Status.Resize)
93
93
} else {
94
-
klog.V(4).Infof("Pod %s is in the process of scaling up (%v state), leaving it in so we can see if it's taking too long", pod.Name, pod.Status.Resize)
94
+
klog.V(4).InfoS("Pod is in the process of scaling up, leaving it in so we can see if it's taking too long", "pod", klog.KObj(pod), "resizeStatus", pod.Status.Resize)
95
95
}
96
96
}
97
97
// I guess if it's not outside of compliance, it's probably okay it's stuck here?
klog.V(2).Infof("Short-lived, but pod still accepted for DISRUPTIONLESS (%d/%d) in-place update %v/%v with priority %v", len(disruptionlessRecommendation.ContainerRecommendations), len(processedRecommendation.ContainerRecommendations), pod.Namespace, pod.Name, updatePriority.ResourceDiff)
141
+
klog.V(2).InfoS("Short-lived, but pod still accepted for disruptionless in-place update",
0 commit comments