Documentation
¶
Overview ¶
Package bunobs configures Bun query logging and telemetry.
Index ¶
Constants ¶
View Source
const ( Local = "local" Dev = "dev" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶
type Option func(*options)
Option configures Bun observability.
func WithLogger ¶
WithLogger sends structured query logs to logger. Configure uses slog.Default when logger is nil or this option is omitted.
func WithOTelOptions ¶
WithOTelOptions configures the Bun OpenTelemetry query hook. Multiple calls append options in order.
func WithQueryText ¶
WithQueryText allows full SQL in structured query logs when enabled. The logger's level still determines which query events are emitted.
Click to show internal directories.
Click to hide internal directories.