Opentelemetry.Span
Spans.
A Span is the workhorse of traces, it indicates an operation that took place over a given span of time (indicated by start_time and end_time) as part of a hierarchical trace. All spans in a given trace are bound by the use of the same Trace_id.t
.
type t = Proto.Trace.span
type id = Span_id.t
type nonrec kind = Proto.Trace.span_span_kind =
type nonrec status_code = Proto.Trace.status_status_code =
val create :
?kind:kind ->
?id:id ->
?trace_state:string ->
?attrs:key_value list ->
?events:Event.t list ->
?status:status ->
trace_id:Trace_id.t ->
?parent:id ->
?links:Span_link.t list ->
start_time:Timestamp_ns.t ->
end_time:Timestamp_ns.t ->
string ->
t * id
create ~trace_id name
creates a new span with its unique ID.