Skip to content

Tracing

rn_forge.web.tracing

W3C Trace Context: the current trace and span ids.

The current trace is read from OpenTelemetry's active span. This module never configures a TracerProvider or an exporter — those are the application's job (or opentelemetry-instrument's), per OpenTelemetry's own library guidance.

EXPOSED_HEADERS = ('ETag', 'Link', 'Location', 'Retry-After', 'Deprecation', 'Sunset', 'Content-Disposition') module-attribute

Response headers this kit emits that a browser can read only when a CORS policy names them in Access-Control-Expose-Headers.

An application's own CORS configuration does not know what the kit emits; a CORS binding passes this list so the kit's own concurrency, discovery and retry contracts survive a browser client. traceresponse is not listed here: the OpenTelemetry response propagator exposes it itself.

TRACE_ID_KEY = 'traceId' module-attribute

The problem-body extension member that carries the current trace id.

current_span_id()

Return the current span's id, or None when no span is recording.

current_trace_id()

Return the current span's trace id, or None when no span is recording.