Merge pull request #62780 from RenaudWasTaken/master
Automatic merge from submit-queue (batch tested with PRs 62780, 62886). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Change Capacity log verbosity in status update *What this PR does / why we need it:* While in production we noticed that the log verbosity for the Capacity field in the node status was to high. This log message is called for every device plugin resource at every update. A proposed solution is to tune it down from V(2) to V(5). In a normal setting you'll be able to see the effect by looking at the node status. Release note: ``` NONE ``` /sig node /area hw-accelerators /assign @vikaschoudhary16 @jiayingz @vishh
This commit is contained in:
commit
48243a9c24
@ -570,7 +570,9 @@ func (kl *Kubelet) setNodeStatusMachineInfo(node *v1.Node) {
|
||||
devicePluginCapacity, devicePluginAllocatable, removedDevicePlugins = kl.containerManager.GetDevicePluginResourceCapacity()
|
||||
if devicePluginCapacity != nil {
|
||||
for k, v := range devicePluginCapacity {
|
||||
glog.V(2).Infof("Update capacity for %s to %d", k, v.Value())
|
||||
if old, ok := node.Status.Capacity[k]; !ok || old.Value() != v.Value() {
|
||||
glog.V(2).Infof("Update capacity for %s to %d", k, v.Value())
|
||||
}
|
||||
node.Status.Capacity[k] = v
|
||||
}
|
||||
}
|
||||
@ -613,9 +615,12 @@ func (kl *Kubelet) setNodeStatusMachineInfo(node *v1.Node) {
|
||||
}
|
||||
node.Status.Allocatable[k] = value
|
||||
}
|
||||
|
||||
if devicePluginAllocatable != nil {
|
||||
for k, v := range devicePluginAllocatable {
|
||||
glog.V(2).Infof("Update allocatable for %s to %d", k, v.Value())
|
||||
if old, ok := node.Status.Allocatable[k]; !ok || old.Value() != v.Value() {
|
||||
glog.V(2).Infof("Update allocatable for %s to %d", k, v.Value())
|
||||
}
|
||||
node.Status.Allocatable[k] = v
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user