6 Commits

Author SHA1 Message Date
7f2aed42a0 Plugins: Fix and encode invalid gRPC header values (#107339)
* Plugins: Fix and encode invalid gRPC header values

* Rename the method

* Run sanitizeHTTPHeaderValueForGRPC only if string includes utf8

* Update test

* Simplify

* Update

* do not double encode encoded characters

* Update test

* Update

* Add test case based on review

* Update test
2025-06-30 15:58:05 +02:00
5a2cba7b01 Plugins: Forward HTTP headers to plugin streaming calls (#101960)
* forward HTTP headers to plugin streaming calls

* fixup

* fix test based on feedback

* improve test assertions
2025-03-12 10:37:07 +00:00
b7a7f2bd62 Plugins: Use handler middleware from the SDK (#93445)
updates sdk to v0.251.0
2024-09-30 16:33:15 +02:00
92965578b3 CloudWatch Logs: Fix running logs queries with expressions (#65306) 2023-03-30 17:40:01 -04:00
7261c6f7cd DataSourceWithBackend: Add queryGroupId to find correlated/related queries (#64587)
* add `correlationId` to queries

* trace correlation id in backend

* add correlation id to loki's span

* add correlation id to query chunks

* fix test

* fix DataSourceWithBackend test

* change to `queryGroupId`

* remove empty line

* fix test in `DataSourceWithBackend`
2023-03-17 15:48:13 +01:00
0485cf34cd Plugins: Pass through dashboard/contextual HTTP headers to plugins/datasources (#60301)
`X-Dashboard-Uid`, `X-Datasource-Uid`, `X-Grafana-Org-Id`, `X-Panel-Id` are very useful headers set
by Grafana front-end that we would like to see on the data source as
well. This is so that it would be possible to pinpoint from where slow
queries are coming in Mimir/Thanos/Cortex/etc., for example. Relevant
Mimir code lines:
0a94f26203/pkg/frontend/transport/handler.go (L182-L184)

Tested manually that with these changes the headers are visible.
2022-12-22 11:15:00 +01:00