Introduce TSDB service (#31520)

* Introduce TSDB service

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
Co-authored-by: Will Browne <will.browne@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.org>
Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
This commit is contained in:
Arve Knudsen
2021-03-08 07:02:49 +01:00
committed by GitHub
co-authored by Erik Sundell Will Browne Torkel Ödegaard Will Browne Zoltán Bedi
parent c899bf3592
commit b79e61656a
203 changed files with 5269 additions and 4776 deletions
+10 -5
View File
@@ -14,12 +14,15 @@ type FrontendPluginBase struct {
PluginBase
}
func (fp *FrontendPluginBase) initFrontendPlugin() {
func (fp *FrontendPluginBase) InitFrontendPlugin() []*PluginStaticRoute {
var staticRoutes []*PluginStaticRoute
if isExternalPlugin(fp.PluginDir) {
StaticRoutes = append(StaticRoutes, &PluginStaticRoute{
Directory: fp.PluginDir,
PluginId: fp.Id,
})
staticRoutes = []*PluginStaticRoute{
{
Directory: fp.PluginDir,
PluginId: fp.Id,
},
}
}
fp.handleModuleDefaults()
@@ -30,6 +33,8 @@ func (fp *FrontendPluginBase) initFrontendPlugin() {
for i := 0; i < len(fp.Info.Screenshots); i++ {
fp.Info.Screenshots[i].Path = evalRelativePluginUrlPath(fp.Info.Screenshots[i].Path, fp.BaseUrl)
}
return staticRoutes
}
func getPluginLogoUrl(pluginType, path, baseUrl string) string {