From 59de772d00ca3a4e125f7275d9199ee3935348ba Mon Sep 17 00:00:00 2001 From: Sebastian Rabenhorst Date: Tue, 23 May 2023 19:57:31 +0200 Subject: [PATCH] Removed unused histogram conversion from remote engine Signed-off-by: Sebastian Rabenhorst --- pkg/query/remote_engine.go | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/pkg/query/remote_engine.go b/pkg/query/remote_engine.go index e52ff0b8edc..091e5a9db76 100644 --- a/pkg/query/remote_engine.go +++ b/pkg/query/remote_engine.go @@ -12,7 +12,6 @@ import ( "github.com/go-kit/log" "github.com/go-kit/log/level" "github.com/pkg/errors" - "github.com/prometheus/prometheus/model/histogram" "github.com/prometheus/prometheus/model/labels" "github.com/prometheus/prometheus/promql" "github.com/prometheus/prometheus/promql/parser" @@ -248,17 +247,9 @@ func (r *remoteQuery) Exec(ctx context.Context) *promql.Result { }) } for _, hp := range ts.Histograms { - var fh *histogram.FloatHistogram - - if hp.IsFloatHistogram() { - fh = prompb.FloatHistogramProtoToFloatHistogram(hp) - } else { - fh = prompb.HistogramProtoToFloatHistogram(hp) - } - series.Histograms = append(series.Histograms, promql.HPoint{ T: hp.Timestamp, - H: fh, + H: prompb.FloatHistogramProtoToFloatHistogram(hp), }) } result = append(result, series)