Remove tags with empty values from Wavefront output (#4266)
This commit is contained in:
parent
b30832dbb1
commit
5ea289dc9d
|
@ -180,6 +180,14 @@ func buildMetrics(m telegraf.Metric, w *Wavefront) []*MetricPoint {
|
||||||
}
|
}
|
||||||
|
|
||||||
func buildTags(mTags map[string]string, w *Wavefront) (string, map[string]string) {
|
func buildTags(mTags map[string]string, w *Wavefront) (string, map[string]string) {
|
||||||
|
|
||||||
|
// Remove all empty tags.
|
||||||
|
for k, v := range mTags {
|
||||||
|
if v == "" {
|
||||||
|
delete(mTags, k)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
var source string
|
var source string
|
||||||
sourceTagFound := false
|
sourceTagFound := false
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue