From 2bbcd2d2aa264d582a50320eb74e77b5e658b1a9 Mon Sep 17 00:00:00 2001 From: Alex Boten <223565+codeboten@users.noreply.github.com> Date: Fri, 19 Apr 2024 10:49:39 -0700 Subject: [PATCH] add name suggestion to prometheus exporter option (#3837) ## Changes Similarly to the other options listed in the Prometheus exporter specification, adding a suggested name for the option to apply resource attributes as metric attributes. --- CHANGELOG.md | 3 +++ specification/metrics/sdk_exporters/prometheus.md | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 52c08bd416d..4b4691192ab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,9 @@ release. ### Metrics +- Add name suggestion for option to apply resource attributes as metric attributes in Prometheus exporter. + ([#3837](https://github.com/open-telemetry/opentelemetry-specification/pull/3837)) + ### Logs ### Events diff --git a/specification/metrics/sdk_exporters/prometheus.md b/specification/metrics/sdk_exporters/prometheus.md index 86c348a3b21..208a6968d49 100644 --- a/specification/metrics/sdk_exporters/prometheus.md +++ b/specification/metrics/sdk_exporters/prometheus.md @@ -44,7 +44,7 @@ A Prometheus Exporter MAY offer configuration to add resource attributes as metr By default, it MUST NOT add any resource attributes as metric attributes. The configuration SHOULD allow the user to select which resource attributes to copy (e.g. include / exclude or regular expression based). Copied Resource attributes MUST NOT be -excluded from the `target` info metric. +excluded from the `target` info metric. The option MAY be named `with_resource_constant_labels`. A Prometheus Exporter MAY support a configuration option to produce metrics without a [unit suffix](../../compatibility/prometheus_and_openmetrics.md#metric-metadata) or UNIT metadata. The option MAY be named `without_units`, and MUST be `false` by default.