Kaynağa Gözat

Merge pull request #2385 from r2k1/fix-unable-to-locate

Log and continue on a single record processing failures.
Cliff Colvin 2 yıl önce
ebeveyn
işleme
40ab230587
1 değiştirilmiş dosya ile 2 ekleme ve 3 silme
  1. 2 3
      pkg/costmodel/costmodel.go

+ 2 - 3
pkg/costmodel/costmodel.go

@@ -2554,9 +2554,8 @@ func (cm *CostModel) QueryAllocation(window kubecost.Window, resolution, step ti
 					}
 
 					if totals == nil {
-						log.Errorf("unable to locate asset totals for allocation %s", key)
-						return nil, fmt.Errorf("unable to locate allocation totals for allocation")
-
+						log.Errorf("unable to locate asset totals for allocation %s, corresponding PARC is being skipped", key)
+						continue
 					}
 
 					parc.CPUTotalCost = totals.CPUCost