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

Set preferred aggregation temporality for the periodic exporting metric reader via environment variable #2065

Closed
pirgeo opened this issue Oct 27, 2021 · 2 comments · Fixed by #2404
Assignees
Labels
area:configuration Related to configuring the SDK area:sdk Related to the SDK release:after-ga Not required before GA release, and not going to work on before GA spec:metrics Related to the specification/metrics directory

Comments

@pirgeo
Copy link
Member

pirgeo commented Oct 27, 2021

What are you trying to achieve?

I want to be able to set the preferred aggregation temporality for an periodic exporting metric reader via an environment variable, e.g. OTEL_METRIC_EXPORT_PREFERRED_TEMPORALITY. If set, This would take precedence over the preferred temporality specified in the MetricReader/MetricExporter (see temporality override rules).

Additional context.

Similar to #2021/#2038, but for aggregation temporality.
Also affects the precedence created in #2031/#2032.

@pirgeo pirgeo added the spec:metrics Related to the specification/metrics directory label Oct 27, 2021
@reyang reyang added the release:after-ga Not required before GA release, and not going to work on before GA label Oct 28, 2021
@arminru arminru added area:configuration Related to configuring the SDK area:sdk Related to the SDK labels Nov 12, 2021
@jack-berg
Copy link
Member

Just to clarify, this is different than the ability to configure temporality for the OTLP exporter? I.e. OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY

@pirgeo
Copy link
Member Author

pirgeo commented Nov 15, 2021

I was thinking about it in more broad terms, i.e. every exporter that supports that environment variable can read it and set the preferred temporality. The mechanism would be the same, but the scope would be a bit bigger. I guess setting it for each exporter individually is also a way to go, and gives you more granular control. These two paths do not interfere with each other, I'd use the more specific (OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY) over the more general variable (OTEL_METRIC_EXPORT_PREFERRED_TEMPORALITY).

I'd envision this as a more general guidance that exporters that don't want to specify their own env var could use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:configuration Related to configuring the SDK area:sdk Related to the SDK release:after-ga Not required before GA release, and not going to work on before GA spec:metrics Related to the specification/metrics directory
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants