Documentation ¶
Overview ¶
Package persistence simplifies the database interaction by providing helper functions it uses sqlx internally
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Atomic ¶
Atomic defines a transactional operation - like the A in ACID https://en.wikipedia.org/wiki/ACID
type Connection ¶
Connection defines a storage/database/... connection
func NewConn ¶
func NewConn(connstr string) Connection
NewConn creates a connection to a store/repository
func NewFromDB ¶
func NewFromDB(db *sqlx.DB) Connection
NewFromDB creates a new connection based on existing DB handle
func (Connection) CreateAtomic ¶
func (c Connection) CreateAtomic() (Atomic, error)
CreateAtomic starts a new transaction
Click to show internal directories.
Click to hide internal directories.