Documentation
¶
Index ¶
- func DBConn() *gorm.DB
- func DBConnWithLoglevel(logMode logger.LogLevel) *gorm.DB
- func GetAccessToken() string
- func GetDatabaseConnectionURL() string
- func GetEvmRpcConfig() config.Config
- func GetGormConfig() *gorm.Config
- func GetNotifyEndPoint() string
- func GetRedisConnectionURL() string
- func RedisConn() *redis.Client
- type Configuration
- type DatabaseConfiguration
- type EvmRpcEndpointConfiguration
- type KafkaConfiguration
- type NotificationConfiguration
- type RedisConfiguration
- type SCInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAccessToken ¶
func GetAccessToken() string
func GetDatabaseConnectionURL ¶
func GetDatabaseConnectionURL() string
func GetEvmRpcConfig ¶
func GetGormConfig ¶
func GetNotifyEndPoint ¶
func GetNotifyEndPoint() string
func GetRedisConnectionURL ¶
func GetRedisConnectionURL() string
Types ¶
type Configuration ¶
type Configuration struct {
Database DatabaseConfiguration `mapstructure:",squash"`
Redis RedisConfiguration `mapstructure:",squash"`
Notify NotificationConfiguration `mapstructure:",squash"`
EvmRpc EvmRpcEndpointConfiguration `mapstructure:",squash"`
Kafka KafkaConfiguration `mapstructure:",squash"`
TestSC SCInfo `mapstructure:",squash"`
AppName string `mapstructure:"APP_NAME"`
AppAddr string `mapstructure:"APP_ADDR"`
ConfigFile string `mapstructure:"CONFIG_FILE"`
DbUrl string `mapstructure:"DB_URL"`
Env string `mapstructure:"ENV"`
CouponSecret string `mapstructure:"COUPON_SECRET"`
}
func GetConfiguration ¶
func GetConfiguration() *Configuration
type DatabaseConfiguration ¶
type KafkaConfiguration ¶
type KafkaConfiguration struct {
KafkaURL string `mapstructure:"KAFKA_URL" yaml:"kafkaUrl" toml:"kafkaUrl" xml:"kafkaUrl" json:"kafkaUrl,omitempty"`
User string `mapstructure:"KAFKA_USER" yaml:"user" toml:"user" xml:"user" json:"user,omitempty"`
Password string `mapstructure:"KAFKA_PASSWORD" yaml:"password" toml:"password" xml:"password" json:"password,omitempty"`
}
type RedisConfiguration ¶
Click to show internal directories.
Click to hide internal directories.