opentelemetry-js
opentelemetry-js copied to clipboard
Configure OTLP metrics exporter with environment variables
https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk_exporters/otlp.md
OTLP exporter spec defines that the OTLP exporter should be automatically configured with a PeriodicMetricReader when using OTEL_METRICS_EXPORTER
. Their aggregation and temporality preferences should also be configured with OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE
and OTEL_EXPORTER_OTLP_METRICS_DEFAULT_HISTOGRAM_AGGREGATION
.
I saw you added this to the metrics GA milestone. Do you believe this is blocking the metrics SDK?
No, I believe it's not blocking but rather good to have.
Just went through the code and saw that the following env-vars from this spec are also not implemented right now:
-
OTEL_EXPORTER_OTLP_METRICS_COMPRESSION
(currently the trace setting is used instead) -
OTEL_EXPORTER_OTLP_METRICS_INSECURE
(currently the trace setting is used instead) -
OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE
(currently the trace setting is used instead) -
OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY
(currently the trace setting is used instead) -
OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE
(currently the trace setting is used instead)
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.
Not stale as we'd need to implement OTEL_EXPORTER_OTLP_METRICS_DEFAULT_HISTOGRAM_AGGREGATION
after #3506 lands. :slightly_smiling_face:
(we also need to address the comment I made earlier)
When this is done, we'll also need to update the spec compliance matrix with the newly supported env vars.