common

package
v0.0.0-...-42cc2d4 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckMysqlError

func CheckMysqlError(err error) myError.Error

Types

type MysqlClient

type MysqlClient struct {
	DB     *gorm.DB
	Master bool
}

MysqlClient mysql连接对象

func ConnectionObject

func ConnectionObject(ctx context.Context) *MysqlClient

ConnectionObject 获取 业务 库客户端连接对象

func NewMysqlClient

func NewMysqlClient(ctx context.Context, name string) *MysqlClient

func (MysqlClient) WithDBContext

func (mc MysqlClient) WithDBContext(ctx context.Context, name string) (*gorm.DB, error)

Jump to

Keyboard shortcuts

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