mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Elasticsearch: Add tracing to data source (#74750)
* Elasticsearch: Add tracing do data source * Fix tests * Address feedback * Update pkg/tsdb/elasticsearch/response_parser.go Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com> * Update pkg/tsdb/elasticsearch/response_parser.go Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com> * Track error across both spans * Add span for decoding of response * Fix test * Update setting of errors + fix test --------- Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/grafana/grafana/pkg/infra/log"
|
||||
"github.com/grafana/grafana/pkg/infra/tracing"
|
||||
es "github.com/grafana/grafana/pkg/tsdb/elasticsearch/client"
|
||||
)
|
||||
|
||||
@@ -1818,6 +1819,6 @@ func executeElasticsearchDataQuery(c es.Client, body string, from, to time.Time)
|
||||
},
|
||||
},
|
||||
}
|
||||
query := newElasticsearchDataQuery(context.Background(), c, dataRequest.Queries, log.New("test.logger"))
|
||||
query := newElasticsearchDataQuery(context.Background(), c, dataRequest.Queries, log.New("test.logger"), tracing.NewFakeTracer())
|
||||
return query.execute()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user