postgres

package
v0.0.0-...-788e3c4 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2022 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ExtFull

type ExtFull struct {
	sqlx.Execer
	sqlx.ExecerContext
	sqlx.Queryer
	sqlx.QueryerContext
	// contains filtered or unexported fields
}

ExtFull is the interface that abstracts all the querying and executing functions of the sqlx package. It is satisfied by the sqlx.DB type.

func NewExtFull

func NewExtFull(l cslog.Logger, p *ExtFullParams) *ExtFull

NewExtFull returns an implementation of ExtFull that uses postgres

WARNING: GetExtFull blocks until a successful connection to the database is achieved This may result in a permanent block if the application cannot connect regardless of number of attempts

func NewExtFullFromTx

func NewExtFullFromTx(l cslog.Logger, tx *sqlx.Tx) *ExtFull

NewExtFullFromTx returns an implementation of ExtFullTx backed by whatever database underlies the db variable provided to it.

type ExtFullParams

type ExtFullParams struct {
	Host     string
	DB       string
	User     string
	Password string
	Port     string
}

ExtFullParams are the params taken to instantiate a new ExtFull

Jump to

Keyboard shortcuts

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