open-telemetry/opentelemetry-dotnet
在 GitHub 查看[otlp] UseOtlpExporter and AddOtlpExporter extensions don't play nice together
Open
#5,538 创建于 2024年4月16日
help wantedpkg:OpenTelemetry.Exporter.OpenTelemetryProtocol
仓库指标
- Star
- (3,725 star)
- PR 合并指标
- (PR 指标待抓取)
描述
In 1.8.0 we introduced the UseOtlpExporter extension which will turn on OtlpExporter for all signals. If UseOtlpExporter is called more than once, or AddOtlpExporter is called in addition, exceptions will be thrown:
-
NotSupportedException: Multiple calls to UseOtlpExporter on the same IServiceCollection are not supported.
-
NotSupportedException: Signal-specific AddOtlpExporter methods and the cross-cutting UseOtlpExporter method being invoked on the same IServiceCollection is not supported.
This was intentionally done but some users have run into issues:
Opening this issue to track the demand for changing the behavior.