From b2c0bc31b40a3bc4a60f952e624fecfd1a8b4539 Mon Sep 17 00:00:00 2001 From: pschork <354473+pschork@users.noreply.github.com> Date: Mon, 29 Jul 2024 12:59:51 -0700 Subject: [PATCH] Average blob throughput over 9m window (#667) --- disperser/dataapi/prometheus_client.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/disperser/dataapi/prometheus_client.go b/disperser/dataapi/prometheus_client.go index 6fd8e1b46b..d1ab1ebb7e 100644 --- a/disperser/dataapi/prometheus_client.go +++ b/disperser/dataapi/prometheus_client.go @@ -47,7 +47,7 @@ func (pc *prometheusClient) QueryDisperserBlobSizeBytesPerSecond(ctx context.Con } func (pc *prometheusClient) QueryDisperserAvgThroughputBlobSizeBytes(ctx context.Context, start time.Time, end time.Time, throughputRateSecs uint16) (*PrometheusResult, error) { - query := fmt.Sprintf("sum by (job) (rate(eigenda_batcher_blobs_total{state=\"confirmed\",data=\"size\",cluster=\"%s\"}[%ds]))", pc.cluster, throughputRateSecs) + query := fmt.Sprintf("avg_over_time( sum by (job) (rate(eigenda_batcher_blobs_total{state=\"confirmed\",data=\"size\",cluster=\"%s\"}[%ds])) [9m:])", pc.cluster, throughputRateSecs) return pc.queryRange(ctx, query, start, end) }