Skip to content

Commit

Permalink
removing help and unit from tags in influx
Browse files Browse the repository at this point in the history
  • Loading branch information
eliska-n committed Oct 11, 2023
1 parent 8b142af commit 5c24ca2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion asab/metrics/influxdb.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ def combine_tags_and_field(tags, values, timestamp):
tags = escape_tags(tags)
values = escape_values(values)
# Then combine the tags and then values
tags_string = ",".join(["{}={}".format(tk, tv) for tk, tv in tags.items()])
tags_string = ",".join(["{}={}".format(tk, tv) for tk, tv in tags.items() if tk not in ("help", "unit")]) # remove "help" and "unit" tags -> utilized in openmetric target
field_set = ",".join([get_field(value_name, value) for value_name, value in values.items()])
return tags_string + " " + field_set + " " + str(int(timestamp * 1e9))

Expand Down

0 comments on commit 5c24ca2

Please sign in to comment.