Expand description
Application-owned telemetry APIs.
Use tracing to compose Encore’s tracing layers, or log to install
Encore’s direct logger for the standard log facade. These are separate
logging paths; choose one. The tracing bridge forwards log records to the
tracing subscriber; it does not forward tracing events to log.
Metrics remain SDK-owned; pass crate::metrics::meter_provider directly
to instrumentation libraries. The SDK does not enable tracing/log.
Entered tracing spans activate their OpenTelemetry context for Encore
resources and other OTel instrumentation, restoring the prior context on
exit. Use tracing::Instrument for futures; never hold an enter guard over
an await. Explicit tracing parents and OpenTelemetrySpanExt::set_parent
are supported. Native OTel contexts nested inside a tracing span take
precedence until detached.
Modules§
- http
- Server spans for HTTP handlers.
- log
- Encore integrations for the standard
logfacade. - tracing
- Encore’s tracing subscriber layers.
Structs§
- Tracer
- An OTel
Tracerrecording into aPipelineunder one instrumentation scope. Cheap to clone. - Tracer
Provider - Encore’s tracer provider, an OpenTelemetry
TracerProviderrecording into the runtime’s telemetry pipeline. Cheap to clone.
Functions§
- parse_
traceparent - Parses a W3C
traceparentheader value and an optionaltracestateinto a remote span context.Nonefor malformed input. - tracer
- A
Tracerrecording into Encore’s pipeline with instrumentation scopename. - tracer_
provider - Encore’s tracer provider.