Support signal-specific OTEL_EXPORTER_OTLP_LOGS_*
and OTEL_EXPORTER_OTLP_TRACES_*
variables
#165
Labels
OTEL_EXPORTER_OTLP_LOGS_*
and OTEL_EXPORTER_OTLP_TRACES_*
variables
#165
Is your feature request related to a problem? Please describe.
When using OTEL env vars implemented in #141 the default env vars are supported, it would be great if also the signal specific LOG env vars are supported and take precedence over the default ones,
Describe the solution you'd like
If I want OTEL logs to be sent to a different sink than metrics or traces i should be able to specify the following env vars defined by OpenTelemetry
OTEL_EXPORTER_OTLP_LOGS_ENDPOINT="http://localhost:5341/ingest/otlp/v1/logs"
OTEL_EXPORTER_OTLP_LOGS_PROTOCOL=http/protobuf
OTEL_EXPORTER_OTLP_LOGS_HEADERS="X-seq-APIKey=xxxxxx"
This should enable metrics and traces to use the defaults and enable sending of logs to a different sink like Seq
I will have to override both metrics and traces signal env vars and have lofs use the defaults - this would be undesirable.
Describe alternatives you've considered
I can achieve this today by setting the defaults for the LOG signal and then override both metrics and traces signal env vars to achieve the correct result - but this is counter intuitive and undesirable.
Additional context
For logs the OTEL_EXPORTER_OTLP_LOGS_* signal env vars should take precedence if they exist, falling back to the defaults OTEL_EXPORTER_OTLP_* when they are not. This how the OTEL SDK works when using UseOtelExporter().
Same would apply to Serilog tracing using the OTEL_EXPORTER_OTLP_TRACES_* env vars though i have only recently discovered that exists and not used it yet.
The text was updated successfully, but these errors were encountered: