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

MetricProducers are passed via config to MetricReaders instead of RegisterProducer #3613

Merged
merged 2 commits into from
Aug 8, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ release.
([#3546](https:/open-telemetry/opentelemetry-specification/pull/3546))
- Revise the exemplar default reservoirs.
([#3627](https:/open-telemetry/opentelemetry-specification/pull/3627))
- MetricProducers are provided as config to MetricReaders instead of through a RegisterProducer operation.
([#3613](https:/open-telemetry/opentelemetry-specification/pull/3613))

### Logs

Expand Down
17 changes: 1 addition & 16 deletions specification/metrics/sdk.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ linkTitle: SDK
+ [AlignedHistogramBucketExemplarReservoir](#alignedhistogrambucketexemplarreservoir)
- [MetricReader](#metricreader)
* [MetricReader operations](#metricreader-operations)
+ [RegisterProducer(metricProducer)](#registerproducermetricproducer)
+ [Collect](#collect)
+ [Shutdown](#shutdown-1)
* [Periodic exporting MetricReader](#periodic-exporting-metricreader)
Expand Down Expand Up @@ -1047,6 +1046,7 @@ SHOULD provide at least the following:
* The default output `aggregation` (optional), a function of instrument kind. If not configured, the [default aggregation](#default-aggregation) SHOULD be used.
* The default output `temporality` (optional), a function of instrument kind. If not configured, the Cumulative temporality SHOULD be used.
* **Status**: [Experimental](../document-status.md) - The default aggregation cardinality limit to use, a function of instrument kind. If not configured, a default value of 2000 SHOULD be used.
* **Status**: [Experimental](../document-status.md) - Zero of more [MetricProducer](#metricproducer)s (optional) to collect metrics from in addition to metrics from the SDK.

The [MetricReader.Collect](#collect) method allows general-purpose
`MetricExporter` instances to explicitly initiate collection, commonly
Expand Down Expand Up @@ -1103,21 +1103,6 @@ functions.

### MetricReader operations

#### RegisterProducer(metricProducer)

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

RegisterProducer causes the MetricReader to use the provided
[MetricProducer](#metricproducer) as a source of aggregated metric data in
subsequent invocations of Collect. RegisterProducer is expected to be called
during initialization, but MAY be invoked later. Multiple registrations
of the same MetricProducer MAY result in duplicate metric data being collected.

If the [MeterProvider](#meterprovider) is an instance of
[MetricProducer](#metricproducer), this MAY be used to register the
MeterProvider, but MUST NOT allow multiple [MeterProviders](#meterprovider)
to be registered with the same MetricReader.

#### Collect

Collects the metrics from the SDK and any registered
Expand Down
Loading