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

Mark Metrics SDK as Mixed/Stable #2150

Closed
wants to merge 13 commits into from
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ release.
([#2131](https://github.com/open-telemetry/opentelemetry-specification/pull/2131))
- Remove the concept of supported temporality, keep preferred.
([#2154](https://github.com/open-telemetry/opentelemetry-specification/pull/2154))
- Mark Metrics SDK spec as Mixed, with `MeterProvider`, `MetricReader` and
`MetricExporter` marked as Stable.
([#2150](https://github.com/open-telemetry/opentelemetry-specification/pull/2150))

### Logs

Expand Down
30 changes: 23 additions & 7 deletions specification/metrics/sdk.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Metrics SDK

**Status**: [Feature-freeze](../document-status.md)
**Status**: [Mixed](../document-status.md)

<details>
<summary>Table of Contents</summary>
Expand Down Expand Up @@ -47,6 +47,8 @@

## MeterProvider

**Status**: [Stable](../document-status.md)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Status**: [Stable](../document-status.md)
**Status**: [Feature-freeze](../document-status.md)


A `MeterProvider` MUST provide a way to allow a [Resource](../resource/sdk.md) to
be specified. If a `Resource` is specified, it SHOULD be associated with all the
metrics produced by any `Meter` from the `MeterProvider`. The [tracing SDK
Expand Down Expand Up @@ -180,17 +182,19 @@ are the inputs:
not in the list will be ignored. If not provided, all the attribute keys
will be used by default (TODO: once the Hint API is available, the default
behavior should respect the Hint if it is available).
* The `extra dimensions` which come from Baggage/Context (optional). If not
provided, no extra dimension will be used. Please note that this only
applies to [synchronous Instruments](./api.md#synchronous-instrument).
* **Status**: [Experimental](../document-status.md) - the `extra dimensions`
reyang marked this conversation as resolved.
Show resolved Hide resolved
which come from Baggage/Context (optional). If not provided, no extra
dimension will be used. Please note that this only applies to [synchronous
Instruments](./api.md#synchronous-instrument).
* The `aggregation` (optional) to be used. If not provided, the SDK MUST
apply a [default aggregation](#default-aggregation). If the aggregation
outputs metric points that use aggregation temporality (e.g. Histogram,
Sum), the SDK SHOULD handle the aggregation temporality based on the
temporality of each [MetricReader](#metricreader) instance.
* The `exemplar_reservoir` (optional) to use for storing exemplars.
This should be a factory or callback similar to aggregation which allows
different reservoirs to be chosen by the aggregation.
* **Status**: [Experimental](../document-status.md) - the `exemplar_reservoir`
(optional) to use for storing exemplars. This should be a factory or
callback similar to aggregation which allows different reservoirs to be
chosen by the aggregation.

The SDK SHOULD use the following logic to determine how to process Measurements
made with an Instrument:
Expand Down Expand Up @@ -422,13 +426,17 @@ This Aggregation informs the SDK to collect:

## Attribute limits

**Status**: [Stable](../document-status.md)

Attributes which belong to Metrics are exempt from the
[common rules of attribute limits](../common/common.md#attribute-limits) at this
time. Attribute truncation or deletion could affect identitity of metric time
series and it requires further analysis.

## Exemplar

**Status**: [Experimental](../document-status.md)

An [Exemplar](./datamodel.md#exemplars) is a recorded
[Measurement](./api.md#measurement) that exposes the following pieces of
information:
Expand Down Expand Up @@ -554,6 +562,8 @@ measurements using the equivalent of the following naive algorithm:

## MetricReader

**Status**: [Stable](../document-status.md)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Status**: [Stable](../document-status.md)
**Status**: [Feature-freeze](../document-status.md)


`MetricReader` is an interface which provides the following capabilities:

* Collecting metrics from the SDK.
Expand Down Expand Up @@ -657,6 +667,8 @@ Configurable parameters:

## MetricExporter

**Status**: [Stable](../document-status.md)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Status**: [Stable](../document-status.md)
**Status**: [Feature-freeze](../document-status.md)


`MetricExporter` defines the interface that protocol-specific exporters MUST
implement so that they can be plugged into OpenTelemetry SDK and support sending
of telemetry data.
Expand Down Expand Up @@ -876,6 +888,8 @@ errors/exceptions are taken care of.

## Compatibility requirements

**Status**: [Stable](../document-status.md)

All the metrics components SHOULD allow new methods to be added to existing
components without introducing breaking changes.

Expand All @@ -884,6 +898,8 @@ existing methods without introducing breaking changes, if possible.

## Concurrency requirements

**Status**: [Stable](../document-status.md)

For languages which support concurrent execution the Metrics SDKs provide
specific guarantees and safeties.

Expand Down