mirror of
https://github.com/grafana/grafana.git
synced 2024-11-27 11:20:27 -06:00
ea8549b8c2
* initial cut at refactor - need to run more tests * fix unit tests * change newly unused function to test helper * create unit tests for parsing query requests that cover a range of cases * add some comments * rename function to avoid dev confusion
12 lines
720 B
Go
12 lines
720 B
Go
package query
|
|
|
|
import (
|
|
"github.com/grafana/grafana/pkg/util/errutil"
|
|
)
|
|
|
|
var (
|
|
ErrNoQueriesFound = errutil.NewBase(errutil.StatusBadRequest, "query.noQueries", errutil.WithPublicMessage("No queries found")).Errorf("no queries found")
|
|
ErrInvalidDatasourceID = errutil.NewBase(errutil.StatusBadRequest, "query.invalidDatasourceId", errutil.WithPublicMessage("Query does not contain a valid data source identifier")).Errorf("invalid data source identifier")
|
|
ErrMissingDataSourceInfo = errutil.NewBase(errutil.StatusBadRequest, "query.missingDataSourceInfo").MustTemplate("query missing datasource info: {{ .Public.RefId }}", errutil.WithPublic("Query {{ .Public.RefId }} is missing datasource information"))
|
|
)
|