-
Notifications
You must be signed in to change notification settings - Fork 881
Prometheus exporter handles instrumentation scope and prevents collisions #3972
Copy link
Copy link
Labels
enhancementNew feature or requestNew feature or requestpkg:OpenTelemetry.Exporter.Prometheus.AspNetCoreIssues related to OpenTelemetry.Exporter.Prometheus.AspNetCore NuGet packageIssues related to OpenTelemetry.Exporter.Prometheus.AspNetCore NuGet package
Description
Now that open-telemetry/opentelemetry-specification#2703 is released, we can update the prometheus exporter to make use of OpenTelemetry scope, particularly for reducing collisions between metrics with the same name.
Describe the solution you'd like
There are a few components:
- Add
otel_scope_nameandotel_scope_versionattributes to all metrics based on the instrumentation scope name and version. - Add an
otel_scope_infometric following https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/compatibility/prometheus_and_openmetrics.md#instrumentation-scope-1. - Prevent collisions between TYPE, HELP, and UNIT comments following https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/compatibility/prometheus_and_openmetrics.md#metric-metadata-1
Note that the exporter SHOULD do the above by default, but may allow disabling the behavior.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestpkg:OpenTelemetry.Exporter.Prometheus.AspNetCoreIssues related to OpenTelemetry.Exporter.Prometheus.AspNetCore NuGet packageIssues related to OpenTelemetry.Exporter.Prometheus.AspNetCore NuGet package