apmpgx

package module
v2.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 11, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Overview

Package apmpgx provides helpers for tracing github.com/jackc/pgx/v4. Minimal required version is v4.17

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrUnsupportedPgxVersion is indicating that data doesn't contain value for "time" key. This field appeared in pgx v4.17
	ErrUnsupportedPgxVersion = errors.New("this version of pgx is unsupported, please upgrade to v4.17+")

	// ErrInvalidType is indicating that field type doesn't meet expected one
	ErrInvalidType = errors.New("invalid field type")
)

Functions

func Instrument

func Instrument(cfg *pgx.ConnConfig)

Instrument is getting pgx.ConnConfig and wrap logger into tracer. It's safe to pass nil logger into pgx.ConnConfig, if so, then only spans will be created

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL