class

OpenTelemetry::API::Span

Inherits OpenTelemetry::Sendable / OpenTelemetry::API::AbstractSpan / OpenTelemetry::Sendable / Reference / Object

A Span represents a single measured timespan, and all data associated with that measurement. A Span may nest other Span instances.

Constants

MATCH = /(?<span_id>[A-Fa-f0-9]{16})/

Constructors

new(name : String = "")
Source

Instance methods

[](key)
Source
[]=(key, value)
Source
add_event(name, attributes : Hash(String, AnyAttribute) = {} of String => AnyAttribute)
Source
add_event(name = "", & : Event -> )
Source
attributes

This is probably a property

Source
attributes=(attributes : Hash(String, AnyAttribute))
Source
can_export?
Source
children

This is probably a property

Source
children=(children : Array(Span))
Source
client!
Source
consumer!
Source
context

This is probably a property

Source
context=(context : SpanContext)
Source
events

This is probably a property

Source
events=(events : Array(Event))
Source
finish

This is probably a property

Source
finish=(finish : Time::Span | Nil)
Source
get_attribute(key)
Source
internal!
Source
is_recording

ameba:disable Style/QueryBoolMethods

Source
is_recording=(is_recording : Bool)

ameba:disable Style/QueryBoolMethods

Source
kind

This is probably a property

Source
kind=(kind : Kind)
Source
name

This is probably a property

Source
name=(name : String)
Source
parent

This is probably a property

Source
parent=(parent : Span | Nil)
Source
producer!
Source
recording?
Source
server!
Source
set_attribute(key, value)
Source
span_id
Source
start

This is probably a property

Source
start=(start : Time::Span)
Source
status

This is probably a property

Source
status=(status : Status)
Source
to_json(json : JSON::Builder)
Source
to_json
Source
to_protobuf

Return the Protobuf object for the Span.

Source
wall_finish

This is probably a property

Source
wall_finish=(wall_finish : Time | Nil)
Source
wall_start

This is probably a property

Source
wall_start=(wall_start : Time)
Source

Nested types