Prometheus: Implement Streaming JSON Parser (#48477)
use `prometheusStreamingJSONParser` feature toggle to enable
This commit is contained in:
@@ -28,7 +28,8 @@ func BenchmarkJson(b *testing.B) {
|
||||
|
||||
b.ResetTimer()
|
||||
for n := 0; n < b.N; n++ {
|
||||
_, _ = s.runQueries(context.Background(), api, []*PrometheusQuery{&query})
|
||||
_, err := s.runQueries(context.Background(), api, []*PrometheusQuery{&query})
|
||||
require.NoError(b, err)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -567,6 +567,7 @@ func deviation(values []float64) float64 {
|
||||
func newDataFrame(name string, typ string, fields ...*data.Field) *data.Frame {
|
||||
frame := data.NewFrame(name, fields...)
|
||||
frame.Meta = &data.FrameMeta{
|
||||
Type: data.FrameTypeTimeSeriesMany,
|
||||
Custom: map[string]string{
|
||||
"resultType": typ,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user