hotel-california-0.0.6.0
Safe HaskellSafe-Inferred
LanguageHaskell2010

HotelCalifornia.Tracing.TraceParent

Description

This module defines the type of TraceParent which can be parsed

Synopsis

Documentation

spanContextFromEnvironment :: IO (Maybe SpanContext) Source #

This function looks up the TRACEPARENT and TRACECONTEXT environment variables and returns a Maybe SpanContext constructed from them.

baggageFromEnvironment :: IO (Maybe Baggage) Source #

This function looks up the BAGGAGE environment variable and returns a Maybe Baggage constructed from that.

spanContextToEnvironment :: Span -> IO [(String, String)] Source #

This function takes the given Span and converts it into a list of environment variables consisting of:

[ ( TRACEPARENT, traceParent)
, ( TRACESTATE, traceState)
, ( BAGGAGE, traceParent)
]

setParentSpanFromEnvironment :: IO () Source #

This function should be called after you've initialized and attached the thread local Context.