Skip to content

Commit f9e53bf

Browse files
committed
Put _count back in to metric format
1 parent f832621 commit f9e53bf

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

mqmetric/discover.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -862,10 +862,11 @@ func formatDescription(elem *MonElement) string {
862862

863863
// There are some metrics that have both "count" and "byte count" in
864864
// the descriptions. They were getting mapped to the same string, so
865-
// we have to ensure uniqueness. We do not put "_count" on the
866-
// metric name.
865+
// we have to ensure uniqueness.
867866
if strings.Contains(elem.Description, "byte count") {
868867
s = s + "_bytes"
868+
} else if strings.HasSuffix(elem.Description," count") && !strings.Contains(s,"_count") {
869+
s = s + "_count"
869870
}
870871
}
871872

0 commit comments

Comments
 (0)