lib/opentelemetry/sdk/trace/export/console_span_exporter.rb in opentelemetry-sdk-0.6.0 vs lib/opentelemetry/sdk/trace/export/console_span_exporter.rb in opentelemetry-sdk-0.7.0
- old
+ new
@@ -12,27 +12,24 @@
module Export
# Outputs {SpanData} to the console.
#
# Potentially useful for exploratory purposes.
class ConsoleSpanExporter
- ResultCodes = OpenTelemetry::SDK::Trace::Export
-
- private_constant(:ResultCodes)
-
def initialize
@stopped = false
end
def export(spans)
- return ResultCodes::FAILURE if @stopped
+ return FAILURE if @stopped
Array(spans).each { |s| pp s }
- ResultCodes::SUCCESS
+ SUCCESS
end
def shutdown
@stopped = true
+ SUCCESS
end
end
end
end
end