From 3ebd0ca752e175104f50f0e1f43aef8c61b42fd7 Mon Sep 17 00:00:00 2001 From: Reiley Yang Date: Wed, 1 Dec 2021 09:11:58 -0800 Subject: [PATCH] Add details to Prometheus Exporter requirement (#2124) * Add details to Prometheus Exporter requirement * fix link * allow push * improve wording * fix typo * fix typo * update based on review feedback * update based on review feedback * update changelog * Apply suggestions from code review Committing these as Reiley has requested for help from native english speakers. Co-authored-by: Tyler Yahn Co-authored-by: Joshua MacDonald Co-authored-by: Tyler Yahn --- CHANGELOG.md | 2 ++ .../metrics/sdk_exporters/prometheus.md | 22 ++++++++++++++++--- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index caa879174fd..f20b80b2bd7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,8 @@ release. ([#2101](https://github.com/open-telemetry/opentelemetry-specification/pull/2101)) - Mark In-memory, OTLP and Stdout exporter specs as Feature-freeze. ([#2131](https://github.com/open-telemetry/opentelemetry-specification/pull/2131)) +- Add details to the Prometheus Exporter requirements. + ([#2124](https://github.com/open-telemetry/opentelemetry-specification/pull/2124)) - Remove the concept of supported temporality, keep preferred. ([#2154](https://github.com/open-telemetry/opentelemetry-specification/pull/2154)) - Mark In-memory, OTLP and Stdout exporter specs as Stable. diff --git a/specification/metrics/sdk_exporters/prometheus.md b/specification/metrics/sdk_exporters/prometheus.md index 4edcf3625b2..c12994a0276 100644 --- a/specification/metrics/sdk_exporters/prometheus.md +++ b/specification/metrics/sdk_exporters/prometheus.md @@ -2,6 +2,22 @@ **Status**: [Experimental](../../document-status.md) -Prometheus Exporter is a [Pull Metric Exporter](../sdk.md#pull-metric-exporter) -which reacts to the Prometheus scraper and report the metrics passively to -[Prometheus](https://prometheus.io/). +A Prometheus Exporter is a [Pull Metric Exporter](../sdk.md#pull-metric-exporter) +which reports metrics by responding to the [Prometheus](https://prometheus.io/) +scraper requests. + +A Prometheus Exporter MUST support [Pull mode](../sdk.md#pull-metric-exporter). + +A Prometheus Exporter MUST NOT support [Push +mode](../sdk.md#push-metric-exporter). + +A Prometheus Exporter MUST only support [Cumulative +Temporality](../datamodel.md#temporality). + +A Prometheus Exporter MUST support version `0.0.4` of the [Text-based +format](https://github.com/prometheus/docs/blob/main/content/docs/instrumenting/exposition_formats.md#text-based-format). + +A Prometheus Exporter MAY support [OpenMetrics Text +Format](https://github.com/prometheus/docs/blob/main/content/docs/instrumenting/exposition_formats.md#openmetrics-text-format), +including the +[Exemplars](https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md#exemplars).