class OpenTelemetry::BatchExporter

Overview

A BatchExporter reports data in batches when either a time or trace-count threshold has been reached. By default, it will report at least once per second in batches of up to 100.

Included Modules

Defined in:

exporter.cr

Constructors

Instance Method Summary

Instance methods inherited from module OpenTelemetry::Exporter

trace(traces : Array(Trace))
trace(trace : Trace)
trace

Constructor Detail

def self.new(exporter : Exporter, duration = 1.second, max_size = 100, log = Log.for(self)) #

Constructor that receives a single exporter


[View source]
def self.new(exporters : Array(Exporter), duration : Time::Span = 1.second, max_size : Int32 = 100, log : Log = Log.for(self)) #

Receives a list of exporters to delegate to


[View source]

Instance Method Detail

def duration : Time::Span #

The maximum amount of time to hold onto data before forwarding it to other exporters.


[View source]
def max_size : Int32 #

The maximum buffer size, for example 100 traces


[View source]
def start #

[View source]
def trace(traces : Array(Trace)) #

Add the given traces to the buffer


[View source]