Structure
PostgresTracingConfiguration
Configures the spans PostgresNIO emits, following the OpenTelemetry database span semantic conventions.
struct PostgresTracingConfiguration
Overview
Each operation creates its span with InstrumentationSystem.tracer, which also picks up withTracer(_:_:). To turn tracing off for an operation, run it inside withTracer(NoOpTracer()).
Topics
Initializers
init()Creates a tracing configuration.
Instance Properties
var databaseSystemName: StringThe value ofdb.system.name. Defaults topostgresql.var recordsQueryText: BoolWhether the query’s SQL is recorded asdb.query.text. Defaults totrue.var recordsReturnedRows: BoolWhether the number of rows received from the server is recorded asdb.response.returned_rows. Defaults tofalse, as the attribute is opt-in and still in development in the spec.
Relationships
Conforms To
Swift.SendableSwift.SendableMetatype