From 26f6b61f12cb193410001ed9bfe07405594daddc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Sep 2023 13:03:08 +0000 Subject: [PATCH 1/2] Bump github.com/grafana/grafana-plugin-sdk-go from 0.173.0 to 0.178.0 Bumps [github.com/grafana/grafana-plugin-sdk-go](https://github.com/grafana/grafana-plugin-sdk-go) from 0.173.0 to 0.178.0. - [Release notes](https://github.com/grafana/grafana-plugin-sdk-go/releases) - [Commits](https://github.com/grafana/grafana-plugin-sdk-go/compare/v0.173.0...v0.178.0) --- updated-dependencies: - dependency-name: github.com/grafana/grafana-plugin-sdk-go dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 6b2d582d..7bc87d0d 100644 --- a/go.mod +++ b/go.mod @@ -6,7 +6,7 @@ require ( github.com/ClickHouse/clickhouse-go/v2 v2.14.1 github.com/docker/docker v24.0.5+incompatible github.com/docker/go-units v0.5.0 - github.com/grafana/grafana-plugin-sdk-go v0.173.0 + github.com/grafana/grafana-plugin-sdk-go v0.178.0 github.com/grafana/sqlds/v2 v2.7.2 github.com/paulmach/orb v0.10.0 github.com/pkg/errors v0.9.1 diff --git a/go.sum b/go.sum index 4685e3e1..bf83f30a 100644 --- a/go.sum +++ b/go.sum @@ -160,8 +160,8 @@ github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e h1:JKmoR8x90Iww1 github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/grafana/grafana-plugin-sdk-go v0.173.0 h1:hZdLi+dF0Y5aRpcjpXyKYRXU7oNpg/wpzTa2/YjWvl0= -github.com/grafana/grafana-plugin-sdk-go v0.173.0/go.mod h1:9crAQqSzxvPe0VKC/T23cd+2I9TZb43yoOcUL/qZ5FU= +github.com/grafana/grafana-plugin-sdk-go v0.178.0 h1:/05wMOSutuMZ/PaRnYHaImPasgblr4x+DMMT4d5Yqmk= +github.com/grafana/grafana-plugin-sdk-go v0.178.0/go.mod h1:9crAQqSzxvPe0VKC/T23cd+2I9TZb43yoOcUL/qZ5FU= github.com/grafana/sqlds/v2 v2.7.2 h1:5bkY9QO5Nc4uAWm3aHF2fHWcOSWhqJmfdJfPRHJVJoo= github.com/grafana/sqlds/v2 v2.7.2/go.mod h1:u5FkkJfuL6EwqesXWjV6cNw7aS5F51sCo/0Op57C8rs= github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI= From 4d5e6df8d32503141047f4e11bd4db82e693f3db Mon Sep 17 00:00:00 2001 From: Adam Yeats Date: Thu, 21 Sep 2023 15:12:49 +0200 Subject: [PATCH 2/2] Pass context to newDatasource as first arg --- pkg/main.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/main.go b/pkg/main.go index f9ea1f19..ab09cb01 100644 --- a/pkg/main.go +++ b/pkg/main.go @@ -1,6 +1,7 @@ package main import ( + "context" "os" "github.com/grafana/clickhouse-datasource/pkg/plugin" @@ -18,7 +19,7 @@ func main() { } } -func newDatasource(settings backend.DataSourceInstanceSettings) (instancemgmt.Instance, error) { +func newDatasource(ctx context.Context, settings backend.DataSourceInstanceSettings) (instancemgmt.Instance, error) { ds := sqlds.NewDatasource(&plugin.Clickhouse{}) return ds.NewDatasource(settings) }