Class: OpenTelemetry::SDK::Trace::Export::ExportError

Inherits:
Error
  • Object
show all
Defined in:
lib/opentelemetry/sdk/trace/export.rb

Overview

Raised when an export fails; spans are available via :spans accessor

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(spans) ⇒ ExportError

Returns a new instance of ExportError.

Parameters:



21
22
23
24
# File 'lib/opentelemetry/sdk/trace/export.rb', line 21

def initialize(spans)
  super("Unable to export #{spans.size} spans")
  @spans = spans
end

Instance Attribute Details

#spansArray<OpenTelemetry::SDK::Trace::Span> (readonly)

Returns the Span array for this exception



18
19
20
# File 'lib/opentelemetry/sdk/trace/export.rb', line 18

def spans
  @spans
end