otel_shelf 0.1.0 copy "otel_shelf: ^0.1.0" to clipboard
otel_shelf: ^0.1.0 copied to clipboard

OpenTelemetry instrumentation for `package:shelf`. Middleware that opens a SERVER span per request, extracts the inbound W3C traceparent and records `http.*` semconv attributes.

Changelog #

0.1.0 - 2026-08-10 #

Added #

  • otelShelfMiddleware({tracer, errorStatusBuilder}) — a shelf Middleware that opens a SERVER span per incoming request with http.request.method, url.full, server.address, server.port, http.response.status_code.
  • Extracts the W3C traceparent header from inbound requests so the device/CLI client's trace stitches into this server span.
  • 5xx flips span status to Error by default; 4xx does not (per OTel HTTP semconv — 4xx is client-side error). Override via errorStatusBuilder.
  • Zone-scoped suppression (runWithoutShelfInstrumentation / async variant).
  • 4 tests including end-to-end traceparent stitching.
0
likes
160
points
68
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

OpenTelemetry instrumentation for `package:shelf`. Middleware that opens a SERVER span per request, extracts the inbound W3C traceparent and records `http.*` semconv attributes.

Homepage
Repository (GitHub)
View/report issues

License

Apache-2.0 (license)

Dependencies

dartastic_opentelemetry, dartastic_opentelemetry_api, shelf

More

Packages that depend on otel_shelf