pgx_driver

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2025 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PGX_DRIVER_CLASS_NAME           = "stdlib.Driver"
	PGX_DRIVER_REGISTRATION_NAME    = "pgx"
	PGX_V5_DRIVER_REGISTRATION_NAME = "pgx/v5"
)

Variables

View Source
var AccessErrors = []string{
	"28P01",
	"28000",
}
View Source
var NetworkErrors = []string{
	"53",
	"57P01",
	"57P02",
	"57P03",
	"58",
	"08",
	"99",
	"F0",
	"XX",
}
View Source
var PgNetworkErrorMessages = []string{
	"unexpected EOF",
	"use of closed network connection",
	"broken pipe",
	"bad connection",
}

Functions

func ClearCaches

func ClearCaches()

Types

type PgxDriver

type PgxDriver struct {
	// contains filtered or unexported fields
}

func (*PgxDriver) Open

func (d *PgxDriver) Open(dsn string) (driver.Conn, error)

type PgxDriverDialect

type PgxDriverDialect struct {
	// contains filtered or unexported fields
}

func NewPgxDriverDialect

func NewPgxDriverDialect() *PgxDriverDialect

func (PgxDriverDialect) GetAllowedOnConnectionMethodNames

func (p PgxDriverDialect) GetAllowedOnConnectionMethodNames() []string

func (PgxDriverDialect) IsClosed

func (p PgxDriverDialect) IsClosed(conn driver.Conn) bool

func (PgxDriverDialect) IsDialect

func (p PgxDriverDialect) IsDialect(driver driver.Driver) bool

func (PgxDriverDialect) IsDriverRegistered

func (p PgxDriverDialect) IsDriverRegistered(drivers map[string]driver.Driver) bool

func (PgxDriverDialect) IsLoginError

func (p PgxDriverDialect) IsLoginError(err error) bool

func (PgxDriverDialect) IsNetworkError

func (p PgxDriverDialect) IsNetworkError(err error) bool

func (PgxDriverDialect) PrepareDsn

func (p PgxDriverDialect) PrepareDsn(properties map[string]string, hostInfo *host_info_util.HostInfo) string

func (PgxDriverDialect) RegisterDriver

func (p PgxDriverDialect) RegisterDriver()

type PgxErrorHandler

type PgxErrorHandler struct {
}

func (*PgxErrorHandler) IsLoginError

func (p *PgxErrorHandler) IsLoginError(err error) bool

func (*PgxErrorHandler) IsNetworkError

func (p *PgxErrorHandler) IsNetworkError(err error) bool

Jump to

Keyboard shortcuts

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