Skip to content

Commit 359388c

Browse files
authored
Merge pull request #2189 from Nordix/log-level-pod-resources
logging: refine logging level in pod resources scanner
2 parents ea6b7f0 + d6d267d commit 359388c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pkg/resourcemonitor/podresourcesscanner.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ func (resMon *PodResourcesScanner) Scan() (ScanResponse, error) {
134134
if err != nil {
135135
klog.ErrorS(err, "failed to calculate fingerprint")
136136
} else {
137-
klog.InfoS("podFingerprint calculated", "status", status.Repr())
137+
klog.V(1).InfoS("podFingerprint calculated", "status", status.Repr())
138138

139139
retVal.Attributes = append(retVal.Attributes, v1alpha2.AttributeInfo{
140140
Name: podfingerprint.Attribute,
@@ -145,7 +145,7 @@ func (resMon *PodResourcesScanner) Scan() (ScanResponse, error) {
145145
var podResData []PodResources
146146

147147
for _, podResource := range respPodResources {
148-
klog.InfoS("scanning pod", "podName", podResource.GetName())
148+
klog.V(1).InfoS("scanning pod", "podName", podResource.GetName())
149149
hasDevice := hasDevice(podResource)
150150
isWatchable, isIntegralGuaranteed, err := resMon.isWatchable(podResource.GetNamespace(), podResource.GetName(), hasDevice)
151151
if err != nil {
@@ -228,7 +228,7 @@ func hasDevice(podResource *podresourcesapi.PodResources) bool {
228228
return true
229229
}
230230
}
231-
klog.InfoS("pod doesn't have devices", "podName", podResource.GetName())
231+
klog.V(1).InfoS("pod doesn't have devices", "podName", podResource.GetName())
232232
return false
233233
}
234234

0 commit comments

Comments
 (0)