Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrRetriesExceeded is returned when a transaction is retried more // than the max allowed valued without a success. ErrRetriesExceeded = errors.New("db tx retries exceeded") )
Functions ¶
func IsSerializationError ¶ added in v1.4.4
IsSerializationError returns true if the given error is a serialization error.
func MapSQLError ¶ added in v1.4.4
MapSQLError attempts to interpret a given error as a database agnostic SQL error.
Types ¶
type ErrSQLUniqueConstraintViolation ¶ added in v1.4.4
type ErrSQLUniqueConstraintViolation struct {
DBError error
}
ErrSQLUniqueConstraintViolation is an error type which represents a database agnostic SQL unique constraint violation.
func (ErrSQLUniqueConstraintViolation) Error ¶ added in v1.4.4
func (e ErrSQLUniqueConstraintViolation) Error() string
type ErrSerializationError ¶ added in v1.4.4
type ErrSerializationError struct {
DBError error
}
ErrSerializationError is an error type which represents a database agnostic error that a transaction couldn't be serialized with other concurrent db transactions.
func (ErrSerializationError) Error ¶ added in v1.4.4
func (e ErrSerializationError) Error() string
Error returns the error message.
func (ErrSerializationError) Unwrap ¶ added in v1.4.4
func (e ErrSerializationError) Unwrap() error
Unwrap returns the wrapped error.
Click to show internal directories.
Click to hide internal directories.