浏览代码

block warning log on idle allocations

Sean Holcomb 5 年之前
父节点
当前提交
632c05d665
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      pkg/kubecost/allocation.go

+ 3 - 1
pkg/kubecost/allocation.go

@@ -1124,7 +1124,9 @@ func (as *AllocationSet) AggregateBy(aggregateBy []string, options *AllocationAg
 		for _, alloc := range aggSet.allocations {
 			for _, sharedAlloc := range shareSet.allocations {
 				if _, ok := shareCoefficients[alloc.Name]; !ok {
-					log.Warningf("AllocationSet.AggregateBy: error getting share coefficienct for '%s'", alloc.Name)
+					if !alloc.IsIdle() {
+						log.Warningf("AllocationSet.AggregateBy: error getting share coefficienct for '%s'", alloc.Name)
+					}
 					continue
 				}