feat(otlp): support OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE#3351
Merged
cijothomas merged 3 commits intoopen-telemetry:mainfrom Feb 17, 2026
Merged
feat(otlp): support OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE#3351cijothomas merged 3 commits intoopen-telemetry:mainfrom
cijothomas merged 3 commits intoopen-telemetry:mainfrom
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3351 +/- ##
======================================
Coverage 82.2% 82.2%
======================================
Files 128 128
Lines 24518 24626 +108
======================================
+ Hits 20161 20267 +106
- Misses 4357 4359 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Merged
2 tasks
cijothomas
reviewed
Feb 16, 2026
cijothomas
reviewed
Feb 16, 2026
cijothomas
reviewed
Feb 16, 2026
|
|
||
| ## vNext | ||
|
|
||
| - Add support for `OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE` environment variable |
cijothomas
reviewed
Feb 16, 2026
cijothomas
reviewed
Feb 16, 2026
Member
cijothomas
left a comment
There was a problem hiding this comment.
Looks good. Left few minor nits - could you address them so I can approve and merge.
… env var Add support for the OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE environment variable per the OTLP Metrics Exporter spec. Accepted values (case-insensitive): cumulative (default), delta, lowmemory. Programmatic .with_temporality() takes priority over the env var. - Add FromStr impl for Temporality in opentelemetry-sdk - Add resolve_temporality() in opentelemetry-otlp to resolve from builder config, env var, or default - Update MetricExporterBuilder to use Option<Temporality> and resolve at build time Signed-off-by: Adrian Cole <[email protected]>
Signed-off-by: Adrian Cole <[email protected]>
be894a9 to
0851213
Compare
Contributor
Author
|
I think I got it. thanks for the quick feedback! |
Signed-off-by: Adrian Cole <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relates to #3283, #3061
Changes
Add support for
OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCEenvironment variableper the OTLP Metrics Exporter spec.
This env var is supported by Go, Python, .NET, JS, PHP, and Ruby SDKs but was missing
from the Rust SDK, requiring users to manually parse it.
Accepted values (case-insensitive):
cumulative(default),delta,lowmemory.Programmatic
.with_temporality()takes priority over the env var.FromStrimpl forTemporalityinopentelemetry-sdkOTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCEconstant andresolve_temporality()inopentelemetry-otlpMetricExporterBuilderresolves temporality from env when not set programmaticallyExporterBuildError::InvalidConfigvariant for invalid env var valuesMerge requirement checklist
CHANGELOG.mdfiles updated for non-trivial, user-facing changes