mysqlKit

package
v2.1.13 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLogger

func NewLogger() logger.Interface

NewLogger

gorm Logger

https://mp.weixin.qq.com/s/R4Q_nChfGBKpMk5WmTg9oQ

gorm 接管日志,使用自义定的输出方式

https://www.likecs.com/show-307107493.html

GromV1 SQL输出到日志文件

https://www.cnblogs.com/guanchaoguo/p/16448416.html

Types

type DsnConfig

type DsnConfig struct {
	UserName string `json:"userName"`
	Password string `json:"password"`
	// Host e.g."127.0.0.1:3306"
	Host   string `json:"host"`
	DBName string `json:"dbName"`
}

func (*DsnConfig) String

func (c *DsnConfig) String() string

type PoolConfig

type PoolConfig struct {
	MaxIdleConns    int           `json:"maxIdleConns"`
	MaxOpenConns    int           `json:"maxOpenConns"`
	ConnMaxLifetime time.Duration `json:"connMaxLifetime"`
}

Jump to

Keyboard shortcuts

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