Documentation
¶
Overview ¶
Package telemetry exposes selected otelsql helpers through the go-service SQL import tree.
This package keeps repository SQL instrumentation on a go-service import path while preserving otelsql behavior for opening instrumented connections, wrapping drivers, and registering DB stats metrics.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Open ¶ added in v2.341.0
Open opens a `database/sql` DB handle with OpenTelemetry instrumentation.
This is a thin wrapper around otelsql.Open.
func RegisterDBStatsMetrics ¶ added in v2.340.0
RegisterDBStatsMetrics registers OpenTelemetry DB stats metrics for db.
This is a thin wrapper around otelsql.RegisterDBStatsMetrics.
Types ¶
type Option ¶ added in v2.340.0
Option is an alias of otelsql.Option.
It configures SQL OpenTelemetry instrumentation behavior such as emitted attributes and metric/tracing options.
func WithAttributes ¶ added in v2.340.0
WithAttributes adds static attributes to SQL telemetry spans and metrics.
This is a thin wrapper around otelsql.WithAttributes.