Remove tags with empty values from Wavefront output (#4266)
This commit is contained in:
parent
f64d612294
commit
d2e729dfaf
|
@ -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