schema

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2020 License: BSD-3-Clause Imports: 3 Imported by: 1

Documentation

Index

Constants

View Source
const (
	MySQLDialect  = "mysql"
	SQLiteDialect = "sqlite"
)

Variables

View Source
var (
	ErrPoolNotFound = errors.New("pool not found")
)

Functions

This section is empty.

Types

type ConfigInterface

type ConfigInterface interface {
	List() []ItemInterface
}

type Connector

type Connector interface {
	Dialect() string
	Pool(string) (*sql.DB, error)
	Reconnect() error
	Close() error
}

type ItemInterface

type ItemInterface interface {
	GetName() string
	GetDSN() string
	Setup(SetupInterface)
}

type SetupInterface

type SetupInterface interface {
	SetMaxIdleConns(int)
	SetMaxOpenConns(int)
	SetConnMaxLifetime(time.Duration)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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