database

package
v0.19.0 Latest Latest
Warning

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

Go to latest
Published: May 4, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultStatementTimeout                = 60 * time.Second
	DefaultIdleInTransactionSessionTimeout = 30 * time.Second
)

Functions

func Conn

func Conn() *gorm.DB

func TruncateTables

func TruncateTables() error

Types

type Config

type Config struct {
	StatementTimeout                time.Duration
	IdleInTransactionSessionTimeout time.Duration
}

func LoadConfig added in v0.19.0

func LoadConfig() Config

type DSNConfig added in v0.19.0

type DSNConfig struct {
	Host            string
	Port            string
	Name            string
	User            string
	Pass            string
	Ssl             string
	ApplicationName string
}

Jump to

Keyboard shortcuts

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