abstract class OpenTelemetry::API::AbstractSpan

Overview

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

Included Modules

Direct Known Subclasses

Defined in:

api/abstract_span.cr
api/span/abstract_kind.cr

Constant Summary

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

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from module OpenTelemetry::Sendable

size size, to_json(json : JSON::Builder)
to_json
to_json
, to_protobuf to_protobuf

Constructor Detail

def self.new(name = "") #

Class Method Detail

def self.build(name = "", &) #

def self.validate_id(id : Slice(UInt8)) #

def self.validate_id(id : Slice) #

Instance Method Detail

abstract def [](key) #

abstract def []=(key, value) #

abstract def add_event(name, attributes : Hash(String, AnyAttribute) = {} of String => AnyAttribute) #

abstract def add_event(name = "", &blk : Event -> ) #

abstract def attributes : Hash(String, AnyAttribute) #

This is probably a property


abstract def attributes=(attributes : Hash(String, AnyAttribute)) #

abstract def can_export? #

abstract def children : Array(Span) #

This is probably a property


abstract def children=(children : Array(Span)) #

abstract def context : SpanContext #

This is probably a property


abstract def context=(context : SpanContext) #

abstract def events : Array(Event) #

This is probably a property


abstract def events=(events : Array(Event)) #

abstract def finish : Time::Span? #

This is probably a property


abstract def finish=(finish : Time::Span?) #

abstract def get_attribute(key) #

abstract def id #

abstract def is_recording : Bool #

This is probably a property


abstract def is_recording=(is_recording : Bool) #

abstract def kind : Kind #

This is probably a property


abstract def kind=(kind : Kind) #

abstract def name : String #

This is probably a property


abstract def name=(name : String) #

abstract def parent : Span? #

This is probably a property


abstract def parent=(parent : Span?) #

abstract def recording? #

abstract def set_attribute(key, value) #

abstract def span_id #

abstract def start : Time::Span #

This is probably a property


abstract def start=(start : Time::Span) #

abstract def status : Status #

This is probably a property


abstract def status=(status : Status) #

abstract def to_json(json : JSON::Builder) #

abstract def to_json #

abstract def to_protobuf #

Return the Protobuf object for the Span.


abstract def wall_finish : Time? #

This is probably a property


abstract def wall_finish=(wall_finish : Time?) #

abstract def wall_start : Time #

This is probably a property


abstract def wall_start=(wall_start : Time) #