sqlx-otel
Lightweight SQLx wrapper that emits OpenTelemetry-native spans and metrics following the database client semantic conventions.
Status
Under development – not yet ready for use.
Planned features
- Database client spans with semconv-compliant naming and attributes
db.client.operation.durationhistogram and other operation/connection pool metrics- Exception events (
db.client.operation.exception) - SQL query text capture with configurable sanitisation
- Feature-gated backends (
sqlite,postgres,mysql) - Zero-cost when no tracer/meter provider is installed
License
Licensed under either of Apache-2.0 or MIT at your option.