Browse Source

Only include thanos offset when thanos is enabled

Matt Bolt 5 years ago
parent
commit
82d98c2f65
1 changed files with 3 additions and 1 deletions
  1. 3 1
      pkg/costmodel/router.go

+ 3 - 1
pkg/costmodel/router.go

@@ -622,7 +622,9 @@ func (p *Accesses) ClusterInfo(w http.ResponseWriter, r *http.Request, ps httpro
 	writeReportingFlags(data)
 
 	// Include Thanos Offset Duration if Applicable
-	data["thanosOffset"] = thanos.Offset()
+	if thanos.IsEnabled() {
+		data["thanosOffset"] = thanos.Offset()
+	}
 
 	w.Write(WrapData(data, err))
 }