lib/opentelemetry/sdk/trace/noop_span_processor.rb in opentelemetry-sdk-0.6.0 vs lib/opentelemetry/sdk/trace/noop_span_processor.rb in opentelemetry-sdk-0.7.0

- old
+ new

@@ -20,11 +20,13 @@ # # This method is called synchronously on the execution thread, should # not throw or block the execution thread. # # @param [Span] span the {Span} that just started. - def on_start(span); end + # @param [Context] parent_context the parent {Context} of the newly + # started span. + def on_start(span, parent_context); end # Called when a {Span} is ended, if the {Span#recording?} # returns true. # # This method is called synchronously on the execution thread, should @@ -38,13 +40,23 @@ # # This method should only be called in cases where it is absolutely # necessary, such as when using some FaaS providers that may suspend # the process after an invocation, but before the `Processor` exports # the completed spans. - def force_flush; end + # + # @return [Integer] Export::SUCCESS if no error occurred, Export::FAILURE if + # a non-specific failure occurred, Export::TIMEOUT if a timeout occurred. + def force_flush + Export::SUCCESS + end # Called when {TracerProvider#shutdown} is called. - def shutdown; end + # + # @return [Integer] Export::SUCCESS if no error occurred, Export::FAILURE if + # a non-specific failure occurred, Export::TIMEOUT if a timeout occurred. + def shutdown + Export::SUCCESS + end end end end end