doitintl/bigquery-grafana

View on GitHub
pkg/main.go

Summary

Maintainability
A
0 mins
Test Coverage
package main

import (
    "os"

    "github.com/grafana/grafana-plugin-sdk-go/backend/datasource"
    "github.com/grafana/grafana-plugin-sdk-go/backend/log"
)

func main() {
    // log.DefaultLogger.Info("Ofir test ************")    //    uncomment and lookup on look to verify you are using correct backend
    // Start listening to requests send from Grafana. This call is blocking so
    // it wont finish until Grafana shutsdown the process or the plugin choose
    // to exit close down by itself
    err := datasource.Serve(newDatasource())

    // Log any error if we could start the plugin.
    if err != nil {
        log.DefaultLogger.Error(err.Error())
        os.Exit(1)
    }
}