You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently authoring a tracing-forest, a Subscriber that performs diagnostics on trace data. We ran into an issue where isahc generates trace data where the entered duration of a parent span is shorter than the entered duration of its children. I've outlined the problem further in this issue. I think I've narrowed down the culprit to these lines:
let span = tracing::trace_span!(parent:&self.span,"header");
let _enter = span.enter();
Here, the parent is passed in to the child and the child is entered, but the parent is not, causing the children to accumulate time while the parent idles. Is there a reason for not entering the parent span, or is this a bug? If it is intended, what is the motivation for it?
I would guess that the fix would look something like this, where the parent span is entered before the child:
let span = tracing::trace_span!(parent:&self.span,"header");let _enter = self.span.enter();// parent enters before the childlet _enter = span.enter();
The text was updated successfully, but these errors were encountered:
Thanks for filing an issue! I'm not actually sure if this is being done by Isahc intentionally or not but is worth digging into. At first guess I suppose maybe I had assumed that entering a child span would cause the parent to be considered "entered" automatically, but maybe that assumption was incorrect. Either way this probably needs fixed.
I'm currently authoring a
tracing-forest
, aSubscriber
that performs diagnostics on trace data. We ran into an issue whereisahc
generates trace data where the entered duration of a parent span is shorter than the entered duration of its children. I've outlined the problem further in this issue. I think I've narrowed down the culprit to these lines:isahc/src/handler.rs
Lines 403 to 404 in 79338ab
Here, the parent is passed in to the child and the child is entered, but the parent is not, causing the children to accumulate time while the parent idles. Is there a reason for not entering the parent span, or is this a bug? If it is intended, what is the motivation for it?
I would guess that the fix would look something like this, where the parent span is entered before the child:
The text was updated successfully, but these errors were encountered: