Documentation ¶
Index ¶
- Variables
- func Close(launcherManager LauncherManager) error
- func GetAuthManager(launcherManager LauncherManager) (authpkg.AuthRepo, error)
- func GetConsulClient(launcherManager LauncherManager) (*consulapi.Client, error)
- func GetJaegerExporter(launcherManager LauncherManager) (*otlptrace.Exporter, error)
- func GetLogger(launcherManager LauncherManager) (log.Logger, error)
- func GetLoggerForHelper() (log.Logger, error)
- func GetLoggerForMiddleware(launcherManager LauncherManager) (log.Logger, error)
- func GetMongoClient(launcherManager LauncherManager) (*mongo.Client, error)
- func GetMysqlDBConn(launcherManager LauncherManager) (*gorm.DB, error)
- func GetPostgresDBConn(launcherManager LauncherManager) (*gorm.DB, error)
- func GetRabbitmqConn(launcherManager LauncherManager) (*amqp.ConnectionWrapper, error)
- func GetRecommendDBConn(launcherManager LauncherManager) (*gorm.DB, error)
- func GetRedisClient(launcherManager LauncherManager) (redis.UniversalClient, error)
- func GetServiceAPIManager(launcherManager LauncherManager) (clientutil.ServiceAPIManager, error)
- func GetTokenManager(launcherManager LauncherManager) (authpkg.TokenManger, error)
- func LoadingConfig(configFilePath string, configOpts ...configutil.Option) (*configpb.Bootstrap, error)
- type LauncherManager
- func NewLauncherManager(configFilePath string, configOpts ...configutil.Option) (LauncherManager, error)
- func NewLauncherManagerWithCleanup(configFilePath string, configOpts ...configutil.Option) (LauncherManager, func(), error)
- func NewSingletonLauncherManager(configFilePath string) (LauncherManager, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var GetDBConn = func(launcherManager LauncherManager) (*gorm.DB, error) { dbConn, err := launcherManager.GetPostgresDBConn() if err != nil { return nil, err } return dbConn, nil }
GetDBConn recommend Postgres
Functions ¶
func Close ¶
func Close(launcherManager LauncherManager) error
func GetAuthManager ¶
func GetAuthManager(launcherManager LauncherManager) (authpkg.AuthRepo, error)
func GetConsulClient ¶
func GetConsulClient(launcherManager LauncherManager) (*consulapi.Client, error)
func GetJaegerExporter ¶
func GetJaegerExporter(launcherManager LauncherManager) (*otlptrace.Exporter, error)
func GetLoggerForHelper ¶
func GetLoggerForMiddleware ¶
func GetLoggerForMiddleware(launcherManager LauncherManager) (log.Logger, error)
func GetMongoClient ¶ added in v0.0.4
func GetMongoClient(launcherManager LauncherManager) (*mongo.Client, error)
func GetMysqlDBConn ¶
func GetMysqlDBConn(launcherManager LauncherManager) (*gorm.DB, error)
func GetPostgresDBConn ¶
func GetPostgresDBConn(launcherManager LauncherManager) (*gorm.DB, error)
func GetRabbitmqConn ¶
func GetRabbitmqConn(launcherManager LauncherManager) (*amqp.ConnectionWrapper, error)
func GetRecommendDBConn ¶ added in v0.0.18
func GetRecommendDBConn(launcherManager LauncherManager) (*gorm.DB, error)
GetRecommendDBConn 获取数据库连接
func GetRedisClient ¶
func GetRedisClient(launcherManager LauncherManager) (redis.UniversalClient, error)
func GetServiceAPIManager ¶ added in v0.0.10
func GetServiceAPIManager(launcherManager LauncherManager) (clientutil.ServiceAPIManager, error)
func GetTokenManager ¶
func GetTokenManager(launcherManager LauncherManager) (authpkg.TokenManger, error)
func LoadingConfig ¶
Types ¶
type LauncherManager ¶
type LauncherManager interface { GetConfig() *configpb.Bootstrap GetLogger() (log.Logger, error) GetLoggerForMiddleware() (log.Logger, error) GetLoggerForHelper() (log.Logger, error) GetRedisClient() (redis.UniversalClient, error) GetMysqlDBConn() (*gorm.DB, error) GetPostgresDBConn() (*gorm.DB, error) GetMongoClient() (*mongo.Client, error) GetConsulClient() (*consulapi.Client, error) GetJaegerExporter() (*otlptrace.Exporter, error) GetRabbitmqConn() (*amqp.ConnectionWrapper, error) GetTokenManager() (authpkg.TokenManger, error) GetAuthManager() (authpkg.AuthRepo, error) GetServiceApiManager() (clientutil.ServiceAPIManager, error) Close() error }
func NewLauncherManager ¶
func NewLauncherManager(configFilePath string, configOpts ...configutil.Option) (LauncherManager, error)
func NewLauncherManagerWithCleanup ¶
func NewLauncherManagerWithCleanup(configFilePath string, configOpts ...configutil.Option) (LauncherManager, func(), error)
func NewSingletonLauncherManager ¶
func NewSingletonLauncherManager(configFilePath string) (LauncherManager, error)
Click to show internal directories.
Click to hide internal directories.