Documentation ¶
Index ¶
- Constants
- func NewTracedHttpHandler(ctx context.Context, appName string, handler http.Handler) (wrappedHandler http.Handler)
- func TraceAddEvent(span OtelSpan, note string)
- func TraceEnd(span OtelSpan)
- func TraceError(span OtelSpan, err error)
- func TraceMapLoadFromJSON(ctx context.Context, b []byte) (newCtx context.Context, err error)
- func TraceMapSerialiseToJSON(ctx context.Context) (b []byte, err error)
- type ContextType
- type OtelExporter
- type OtelSpan
- type OtelTracer
- type ShutdownTracerFn
Constants ¶
View Source
const ( CONTEXT_APPNAME ContextType = "appName" CONTEXT_CAUSATION_ID = "causationId" CONTEXT_CORRELATION_ID = "correlationId" CONTEXT_LOG_ENABLED = "LOG_ENABLED" CONTEXT_LOG_LEVEL = "LOG_LEVEL" )
Variables ¶
This section is empty.
Functions ¶
func NewTracedHttpHandler ¶
func TraceAddEvent ¶
An event is a human-readable message on a span that represents “something happening” during it’s lifetime.
func TraceError ¶
func TraceMapLoadFromJSON ¶
Deserialise the tracing context from a JSON byte array e.g. when received from a message payload that has passed through a broker
Types ¶
type ContextType ¶
type ContextType string
type OtelExporter ¶
type OtelExporter *stdouttrace.Exporter
wrap otel objects so clients avoid additional imports
type OtelSpan ¶
wrap otel objects so clients avoid additional imports
func TraceSetStringAttribute ¶
type OtelTracer ¶
wrap otel objects so clients avoid additional imports
func NewTracer ¶
func NewTracer(ctx context.Context, appName string, tp *sdktrace.TracerProvider) (t OtelTracer)
type ShutdownTracerFn ¶
type ShutdownTracerFn func()
func ConfigureFileTracing ¶
func ConfigureStdoutTracing ¶
Click to show internal directories.
Click to hide internal directories.