opentelemetry-rust
opentelemetry-rust copied to clipboard
Tracer does weak->Arc upgrade twice in hot path leading to bottleneck
Tracer holds a weakref to its TracerProvider and attempts to upgrade that to an Arc twice in the hot path - one during span start and then again during span end. This is affecting throughput due to contention.
This issue is already fixed for Logs, opening a new issue to track fixing the same for traces.
Will take a look this week
- Make the span processor shutdown from any reference #1836
- Add
shutdownto sdk tracer provider #1855 - Remove
global::shutdown_global_tracer_providerhttps://github.com/open-telemetry/opentelemetry-rust/pull/2369/ - Now tracer provider can take a
TracerProviderInnerArc pointer. #1855
This is done. Closing the issue.