Adding note about behavior of .+ regex

Signed-off-by: Pedro Tanaka <pedro.stanaka@gmail.com>
This commit is contained in:
Pedro Tanaka 2022-06-29 10:18:15 +02:00
parent f935a9c869
commit 1a148215de

View file

@ -334,6 +334,8 @@ mappings:
If a metric `my.statsd_counter` is received, the metric name will **still** be mapped to `my_statsd_counter` (Prometheus compatible name). If a metric `my.statsd_counter` is received, the metric name will **still** be mapped to `my_statsd_counter` (Prometheus compatible name).
But the metric will also have the label `statsd_metric_name` with the value `my.statsd_counter` (unchanged value). But the metric will also have the label `statsd_metric_name` with the value `my.statsd_counter` (unchanged value).
Note: If you use the `match` like the example (i.e. `.+`), be aware that it will be a "catch-all" block. So it should come at the very end of the mapping list.
The same is not achievable with glob matching, for more details check [this issue](https://github.com/prometheus/statsd_exporter/issues/438). The same is not achievable with glob matching, for more details check [this issue](https://github.com/prometheus/statsd_exporter/issues/438).
### Naming, labels, and help ### Naming, labels, and help