lib/opentelemetry/sdk/trace/export/simple_span_processor.rb in opentelemetry-sdk-0.2.0 vs lib/opentelemetry/sdk/trace/export/simple_span_processor.rb in opentelemetry-sdk-0.3.0

- old
+ new

@@ -50,10 +50,19 @@ @span_exporter&.export([span.to_span_data]) rescue => e # rubocop:disable Style/RescueStandardError OpenTelemetry.logger.error("unexpected error in span.on_finish - #{e}") end - # Called when {TracerFactory#shutdown} is called. + # Export all ended spans to the configured `Exporter` that have not yet + # been exported. + # + # 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 + + # Called when {TracerProvider#shutdown} is called. def shutdown @span_exporter&.shutdown end end end