Documentation ¶
Index ¶
- Constants
- func DB() *gorm.DB
- func GetAutoSliceDB(db *gorm.DB, userId int64, sf SP) *gorm.DB
- func InitQpsDB(limit int, interval time.Duration)
- func OpenMysqlDB(dbType string, dbUrl string, config *gorm.Config, ...) (instance *gorm.DB, err error)
- func QpsDB() *gorm.DB
- func SetMainDB(main *gorm.DB, DSN string)
- type SP
Constants ¶
View Source
const ( EmptyVal = "" PartOnlyOne = 1 )
View Source
const ( // MYSQL dbType MYSQL = "mysql" // PG dbType PG = "postgres" )
Variables ¶
This section is empty.
Functions ¶
func GetAutoSliceDB ¶ added in v1.2.6
GetAutoSliceDB 获取自动分表
Types ¶
Click to show internal directories.
Click to hide internal directories.