opentracing-0.1.0.0: OpenTracing for Haskell
Safe HaskellNone
LanguageHaskell2010

OpenTracing.Reporting.Batch

Description

This module provides a trace reporter that groups recorded spans into batches before sending them to their destination in bulk.

Synopsis

Documentation

data BatchOptions Source #

Options available to construct a batch reporter. Default options are available with batchOptions

batchOptions :: ([FinishedSpan] -> IO ()) -> BatchOptions Source #

Default batch options which can be overridden via lenses.

defaultErrorLog :: Builder -> IO () Source #

An error logging function which prints to stderr.

data BatchEnv Source #

The environment of a batch reporter.

newBatchEnv :: BatchOptions -> IO BatchEnv Source #

Create a new batch environment

closeBatchEnv :: BatchEnv -> IO () Source #

Close a batch reporter, stop consuming any new spans. Any spans in the queue will be drained.

batchReporter :: MonadIO m => BatchEnv -> FinishedSpan -> m () Source #

An implementation of tracerReport that batches the finished spans for transimission to their destination.