reqwest-tracing
has opentelemetry
logic even when no opentelemetry is not used
#206
Labels
bug
Something isn't working
First of all, thank you for making this crate!
Bug description
When using
reqwest-tracing
without any of theopentelemetry
features enabled, the crate still contains quite a bit of code related to and crates needed foropentelemetry
. Example of crates arematchit
, which does routing.To Reproduce
The easiest example I can find:
reqwest-tracing
as dependency without any enabled features.Cargo.lock
and notice it containsmatchit
(for routing logic).Expected behavior
I would expect the crate to be slimmer and contain only the required dependencies needed to get
tracing
working.Environment
reqwest-tracing
:0.5.4
rustc
:1.83.0
Additional context
After inspecting the code I understand that "simply not adding it" isn't as easy as it sounds and that this might not be solved in the near future. Hence might I mention, as food for thought, that splitting the
opentelemetry
logic ofreqwest-tracing
into a separatereqwest-opentelemetry
crate might be a method to make this simpler?On the other hand I can also imagine that I am not fully understanding the codebase (as I've just looked through it after noticing the
matchit
dep), so I might be fully wrong here. Please let me know so and feel free to close this if that's the case!The text was updated successfully, but these errors were encountered: