Skip to main content

Module telemetry

Module telemetry 

Source
Expand description

Telemetry facade. Currently wraps Sentry. Designed for extraction to docspec-telemetry when (a) OpenTelemetry is added, OR (b) docspec-cli wants Sentry, OR (c) Prometheus metrics land. Keep the public API surface stable and free of HTTP-specific types.

Modules§

sentry
Sentry telemetry backend internals.

Structs§

TelemetryGuard
Keeps the telemetry client alive until shutdown so buffered events can flush.

Functions§

init
Initializes telemetry from the configured environment and returns its guard.
tower_http_layer
Returns a tower HTTP layer that enriches Sentry events when telemetry is initialized.
tower_new_layer
Returns a tower layer that binds a Sentry hub to each request when telemetry is initialized.
tracing_layer
Returns a Sentry tracing layer when telemetry is initialized.