Merge pull request #9752 from mtanda/cw_alias_fix

[bug fix] (cloudwatch) fix default alias format
pull/9767/merge
Carl Bergquist 8 years ago committed by GitHub
commit 17492c091a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      pkg/tsdb/cloudwatch/cloudwatch.go

@ -267,7 +267,10 @@ func parseQuery(model *simplejson.Json) (*CloudWatchQuery, error) {
period = int(d.Seconds())
}
alias := model.Get("alias").MustString("{{metric}}_{{stat}}")
alias := model.Get("alias").MustString()
if alias == "" {
alias = "{{metric}}_{{stat}}"
}
return &CloudWatchQuery{
Region: region,

Loading…
Cancel
Save