feat(cloudwatch): refactoring and cleanup of backend code, started moving hard coded stuff in the frontend to the backend, changed name of metricFind queries region() -> regions() , and namespace() -> namespaces() to be more consistent with the others, #684

This commit is contained in:
Torkel Ödegaard
2015-10-02 11:10:21 +02:00
parent 04f4454974
commit 180ba33ac8
6 changed files with 174 additions and 144 deletions
+2 -1
View File
@@ -8,6 +8,7 @@ import (
"net/url"
"time"
"github.com/grafana/grafana/pkg/api/cloudwatch"
"github.com/grafana/grafana/pkg/bus"
"github.com/grafana/grafana/pkg/middleware"
m "github.com/grafana/grafana/pkg/models"
@@ -83,7 +84,7 @@ func ProxyDataSourceRequest(c *middleware.Context) {
}
if query.Result.Type == m.DS_CLOUDWATCH {
ProxyCloudWatchDataSourceRequest(c)
cloudwatch.HandleRequest(c)
} else {
proxyPath := c.Params("*")
proxy := NewReverseProxy(&ds, proxyPath, targetUrl)