Open
Description
In this code:
There's no good reason to set the attributes only after checking is_recording
, except:
- when
enable_commenter
andenable_attribute_commenter
are both true - specifically for the statement attribute
- assuming that it's important that the initial and final values of the statement attribute are the same.
Otherwise, it's computationally trivial to include those attributes when starting the span. This would allow samplers to exclude spans with particular attributes (especially certain trivial queries which aren't worth tracing), and SpanProcessor.on_start
to make use of the attributes.
Metadata
Metadata
Assignees
Labels
No labels