open-telemetry / opentelemetry-specification

Specifications for OpenTelemetry
https://opentelemetry.io
Apache License 2.0
3.76k stars 890 forks source link

Prometheus exporter config -> type_suffix needs clarification #4265

Open psx95 opened 1 month ago

psx95 commented 1 month ago

What are you trying to achieve?

The current prometheus exporter spec suggests that there can be a configuration - without_type_suffix which if enabled, produces metrics without type_suffix.

IIUC, this only applies to _total that gets added in case counters are used. Unlike units, the possible values of type_suffix are not apparent when reading the metric metadata portion of the spec.

This could cause some confusion where type_suffix could be confused with _bucket or _sum that gets added to the metrics when using histograms or summaries.

What did you expect to see?

If the only possible type_suffix, currently is a _total. The config option could be renamed to without_counter_suffix OR the spec mentions that without_type_suffix only affects Counters.

I'm not sure if this is a legitimate ask, but I feel making this more explicit could be useful.