CloudWatch: Move logger to its own package and minor refactoring (#57107)

* Move log to its own package

* Rename test-data to testdata

* Change alias to string type

* Remove parseQueries from a method of cloudWatchExecutor
This commit is contained in:
Shirley
2022-10-18 04:21:18 -04:00
committed by GitHub
parent 2815343ee5
commit 65939ce5b1
14 changed files with 56 additions and 37 deletions
+3 -1
View File
@@ -6,6 +6,8 @@ import (
"net/url"
"strings"
"time"
"github.com/grafana/grafana/pkg/tsdb/cloudwatch/cwlog"
)
type cloudWatchQuery struct {
@@ -41,7 +43,7 @@ func (q *cloudWatchQuery) getGMDAPIMode() gmdApiMode {
return GMDApiModeSQLExpression
}
plog.Warn("Could not resolve CloudWatch metric query type. Falling back to metric stat.", "query", q)
cwlog.Warn("Could not resolve CloudWatch metric query type. Falling back to metric stat.", "query", q)
return GMDApiModeMetricStat
}