Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce logging in scale calculation #3642

Merged
merged 1 commit into from
Oct 26, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Reduce logging in scale calculation
  • Loading branch information
mcristina422 committed Oct 23, 2020
commit 67ae3d9eb891dd0d74d817417f92d8baa8132d36
3 changes: 2 additions & 1 deletion cluster-autoscaler/core/scale_down.go
Original file line number Diff line number Diff line change
Expand Up @@ -418,13 +418,14 @@ func (sd *ScaleDown) checkNodeUtilization(timestamp time.Time, node *apiv1.Node,
if err != nil {
klog.Warningf("Failed to calculate utilization for %s: %v", node.Name, err)
}
klog.V(4).Infof("Node %s - %s utilization %f", node.Name, utilInfo.ResourceName, utilInfo.Utilization)

if !sd.isNodeBelowUtilizationThreshold(node, utilInfo) {
klog.V(4).Infof("Node %s is not suitable for removal - %s utilization too big (%f)", node.Name, utilInfo.ResourceName, utilInfo.Utilization)
return simulator.NotUnderutilized, &utilInfo
}

klog.V(4).Infof("Node %s - %s utilization %f", node.Name, utilInfo.ResourceName, utilInfo.Utilization)

return simulator.NoReason, &utilInfo
}

Expand Down