Просмотр исходного кода

Removed IsThanosEnabled check

Removed 'IsThanosEnabled' check as it is not required and possibly causing issues for some users.

Signed-off-by: Jason Charcalla <jason@kubecost.com>
Jason Charcalla 3 лет назад
Родитель
Сommit
03dda4bdff
1 измененных файлов с 0 добавлено и 16 удалено
  1. 0 16
      pkg/env/costmodelenv.go

+ 0 - 16
pkg/env/costmodelenv.go

@@ -479,22 +479,6 @@ func GetETLMaxPrometheusQueryDuration() time.Duration {
 	return mins * time.Minute
 }
 
-// GetETLResolution determines the resolution of ETL queries. The smaller the
-// duration, the higher the resolution; the higher the resolution, the more
-// accurate the query results, but the more computationally expensive. This
-// value is always 1m for Prometheus, but is configurable for Thanos.
-func GetETLResolution() time.Duration {
-	// If Thanos is not enabled, hard-code to 1m resolution
-	if !IsThanosEnabled() {
-		return 60 * time.Second
-	}
-
-	// Thanos is enabled, so use the configured ETL resolution, or default to
-	// 5m (i.e. 300s)
-	secs := time.Duration(GetInt64(ETLResolutionSeconds, 300))
-	return secs * time.Second
-}
-
 func LegacyExternalCostsAPIDisabled() bool {
 	return GetBool(LegacyExternalAPIDisabledVar, false)
 }