setup

package
Version: v0.0.0-...-7f422e9 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2021 License: GPL-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMySQL

func NewMySQL(mysqlSetting *setting.MysqlSettingS) (*gorm.DB, error)

NewMySQL returns *gorm.DB instance.

func NewRedis

func NewRedis(redisSetting *setting.RedisSettingS) (*redis.Pool, error)

func SetCreateCallback

func SetCreateCallback(db *gorm.DB, callback func(scope *gorm.Scope))

SetCreateCallback is set create callback

func SetDeleteCallback

func SetDeleteCallback(db *gorm.DB, callback func(scope *gorm.Scope))

SetDeleteCallback is set delete callback

func SetUpAliAMQPQueue

func SetUpAliAMQPQueue(aliAMQPQueueSetting *setting.QueueAliAMQPSettingS, namedTaskFuncs map[string]interface{}) *queue.MachineryQueue

SetUpAliAMQPQueue returns *queue.MachineryQueue instance of aliyun AMQP queue.

func SetUpRedisQueue

func SetUpRedisQueue(redisQueueSetting *setting.QueueRedisSettingS, namedTaskFuncs map[string]interface{}) *queue.MachineryQueue

SetUpRedisQueue returns *queue.MachineryQueue instance of redis queue.

func SetUpdateCallback

func SetUpdateCallback(db *gorm.DB, callback func(scope *gorm.Scope))

SetUpdateCallback is set update callback

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL