Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add details to Prometheus Exporter requirement #2124

Merged
merged 16 commits into from
Dec 1, 2021
Merged
32 changes: 29 additions & 3 deletions specification/metrics/sdk_exporters/prometheus.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,32 @@

**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/).
Prometheus Exporter is a [MetricExporter](../sdk.md#metricexporter) which reacts
to the Prometheus scraper and reports the metrics passively to
[Prometheus](https://prometheus.io/), or [pushes
metrics](https://prometheus.io/docs/instrumenting/pushing/) to a [Prometheus
Pushgateway](https:/prometheus/pushgateway).
jmacd marked this conversation as resolved.
Show resolved Hide resolved

Prometheus Exporter SHOULD support [Pull mode](../sdk.md#pull-metric-exporter),
if possible.
jmacd marked this conversation as resolved.
Show resolved Hide resolved

Prometheus Exporter MAY support [Push mode](../sdk.md#push-metric-exporter), if
there is a need to support short-lived applications (e.g. short-lived
service-level batch jobs, JavaScript applications running inside web browsers,
etc.).
reyang marked this conversation as resolved.
Show resolved Hide resolved

Prometheus Exporter MUST support version `0.0.4` of the [Text-based
jmacd marked this conversation as resolved.
Show resolved Hide resolved
format](https:/prometheus/docs/blob/main/content/docs/instrumenting/exposition_formats.md#text-based-format).

Prometheus Exporter SHOULD only support [Cumulative
Temporality](../datamodel.md#temporality). Attempt to change the [Aggregation
Temporality](../datamodel.md#temporality) to
[Delta](../datamodel.md#temporality) SHOULD be treated as an error. It is
reyang marked this conversation as resolved.
Show resolved Hide resolved
unspecified _how_ the this error should be handled (e.g. it could fail fast
during the exporter configuration time). Please refer to [Error handling in
OpenTelemetry](../../error-handling.md) for the general guidance.

Prometheus Exporter MAY support [OpenMetrics Text
jmacd marked this conversation as resolved.
Show resolved Hide resolved
Format](https:/prometheus/docs/blob/main/content/docs/instrumenting/exposition_formats.md#openmetrics-text-format),
including the
[Exemplars](https:/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md#exemplars).