|
@@ -3,22 +3,20 @@ package proxy
|
|
|
import (
|
|
import (
|
|
|
"golang.org/x/net/context"
|
|
"golang.org/x/net/context"
|
|
|
|
|
|
|
|
- //tsdb "github.com/grafana/grafana/pkg/tsdb"
|
|
|
|
|
-
|
|
|
|
|
proto "github.com/grafana/grafana/pkg/tsdb/models"
|
|
proto "github.com/grafana/grafana/pkg/tsdb/models"
|
|
|
plugin "github.com/hashicorp/go-plugin"
|
|
plugin "github.com/hashicorp/go-plugin"
|
|
|
"google.golang.org/grpc"
|
|
"google.golang.org/grpc"
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
-var PluginMap = map[string]plugin.Plugin{
|
|
|
|
|
- "tsdb_mock": &TsdbPluginImpl{},
|
|
|
|
|
-}
|
|
|
|
|
|
|
+// var PluginMap = map[string]plugin.Plugin{
|
|
|
|
|
+// "tsdb_mock": &TsdbPluginImpl{},
|
|
|
|
|
+// }
|
|
|
|
|
|
|
|
type TsdbPlugin interface {
|
|
type TsdbPlugin interface {
|
|
|
Query(ctx context.Context, req *proto.TsdbQuery) (*proto.Response, error)
|
|
Query(ctx context.Context, req *proto.TsdbQuery) (*proto.Response, error)
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-type TsdbPluginImpl struct { //LOL IMPL LOL
|
|
|
|
|
|
|
+type TsdbPluginImpl struct {
|
|
|
plugin.NetRPCUnsupportedPlugin
|
|
plugin.NetRPCUnsupportedPlugin
|
|
|
Plugin TsdbPlugin
|
|
Plugin TsdbPlugin
|
|
|
}
|
|
}
|