Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type JaegerData ¶
type Span ¶
type Span struct {
// Name is the name of a specific span
Name string
// SpanContext is the unique SpanContext that identifies the span
SpanContext trace.SpanContext
// Parten is the unique SpanContext that identifies the parent of the span.
// If the span has no parent, this span context will be invalid.
Parent trace.SpanContext
// SpanKind is the role the span plays in a Trace
SpanKind trace.SpanKind
// StartTime is the time the span started recording
StartTime time.Time
// EndTime returns the time the span stopped recording
EndTime time.Time
// Attributes are the defining attributes of a span
Attributes []attribute.KeyValue
// Events are all the events that occurred within the span
Events []tracesdk.Event
// Links are all the links the span has to other spans
Links []tracesdk.Link
// Status is that span status
Status tracesdk.Status
// DroppedAttributes is the number of attributes dropped by the span due to
// a limit being reached
DroppedAttributes int
// DroppedEvents is the number of attributes dropped by the span due to a
// limit being reached
DroppedEvents int
// DroppedLinks is the number of links dropped by the span due to a limit
// being reached
DroppedLinks int
// ChildSpanCount is the count of spans that consider the span a direct
// parent
ChildSpanCount int
// Resource is the information about the entity that produced the span
// We have to change this type from the otel type to make this struct
// marshallable
Resource []attribute.KeyValue
// InstrumentationLibrary is information about the library that produced
// the span
InstrumentationLibrary instrumentation.Scope
}
Span is a type similar to otel's SpanStub, but with the correct types needed for handle marshaling and unmarshalling.
func (*Span) Snapshot ¶
func (s *Span) Snapshot() tracesdk.ReadOnlySpan
Snapshot turns a Span into a ReadOnlySpan which is exportable by otel.
func (*Span) UnmarshalJSON ¶
UnmarshalJSON implements json.Unmarshaler for Span which allows correctly retrieving attribute.KeyValue values.
type Spans ¶
type Spans []Span
func ParseSpanStubs ¶
ParseSpanStubs parses BuildKit trace data into a list of SpanStubs.
func (Spans) JaegerData ¶
func (s Spans) JaegerData() JaegerData
JaegerData return Jaeger data compatible with ui import feature. https://github.com/jaegertracing/jaeger-ui/issues/381#issuecomment-494150826
func (Spans) ReadOnlySpans ¶
func (s Spans) ReadOnlySpans() []tracesdk.ReadOnlySpan
ReadOnlySpans return a list of tracesdk.ReadOnlySpan from span stubs.
Click to show internal directories.
Click to hide internal directories.