Documentation ¶
Index ¶
- Constants
- func GetClientAddrs() []string
- func GetCoordinatorType() string
- func GetDSN() string
- func GetFixedWorkerID() int64
- func GetMaxProdNumber() int32
- func GetRedisAddr() string
- func GetReleaseTimestamp() uint64
- func IsOpenTimeCheckSwitch() bool
- func Parse(path string) error
- type CoordinatorConfig
- type EkkoConfig
- type EtcdConfig
- type MySQLConfig
- type RedisConfig
Constants ¶
View Source
const ( CoordinatorTypeNone = "none" CoordinatorTypeMysql = "mysql" CoordinatorTypeEtcd = "etcd" CoordinatorTypeRedis = "redis" )
Variables ¶
This section is empty.
Functions ¶
func GetClientAddrs ¶
func GetClientAddrs() []string
func GetCoordinatorType ¶
func GetCoordinatorType() string
func GetFixedWorkerID ¶
func GetFixedWorkerID() int64
func GetMaxProdNumber ¶
func GetMaxProdNumber() int32
func GetRedisAddr ¶
func GetRedisAddr() string
func GetReleaseTimestamp ¶
func GetReleaseTimestamp() uint64
func IsOpenTimeCheckSwitch ¶
func IsOpenTimeCheckSwitch() bool
Types ¶
type CoordinatorConfig ¶
type CoordinatorConfig interface {
Check() error
}
type EkkoConfig ¶
type EkkoConfig struct { ReleaseDate string `toml:"release_date"` MaxProductionNumber int32 `toml:"max_production_number"` FixedWorkerID int64 `toml:"fixed_worker_id"` CoordinatorType string `toml:"coordinator_type"` OpenTimeCheckSwitch bool `toml:"open_time_check_switch"` ReleaseTimestamp uint64 Etcd EtcdConfig `toml:"etcd"` Mysql MySQLConfig `toml:"mysql"` Redis RedisConfig `toml:"redis"` }
type EtcdConfig ¶
type EtcdConfig struct {
ClientAddrs []string `toml:"client_addrs"`
}
func (*EtcdConfig) Check ¶
func (e *EtcdConfig) Check() error
type MySQLConfig ¶
type MySQLConfig struct {
Dsn string `toml:"dsn"`
}
func (*MySQLConfig) Check ¶
func (m *MySQLConfig) Check() error
type RedisConfig ¶
type RedisConfig struct {
ServerAddr string `toml:"server_addr"`
}
func (*RedisConfig) Check ¶
func (r *RedisConfig) Check() error
Click to show internal directories.
Click to hide internal directories.