Versions in this module Expand all Collapse all v2 v2.2.5 Dec 2, 2019 Changes in this version + const APP_CONFIG_FILE_NAME + const ENV_CONFIG_FILE_PATH + func AddChangeListener(listener ChangeListener) + func GetApolloConfigCache() agcache.CacheInterface + func GetBoolValue(key string, defaultValue bool) bool + func GetConfigCache(namespace string) agcache.CacheInterface + func GetCurrentApolloConfig() map[string]*ApolloConnConfig + func GetFloatValue(key string, defaultValue float64) float64 + func GetIntValue(key string, defaultValue int) int + func GetStringValue(key string, defaultValue string) string + func InitCustomConfig(loadAppConfig func() (*AppConfig, error)) + func SetCache(cacheFactory *agcache.DefaultCacheFactory) + func SetLogger(loggerInterface LoggerInterface) + func Start() error + func StartRefreshConfig(component AbsComponent) + func StartWithCache(cacheFactory *agcache.DefaultCacheFactory) error + func StartWithLogger(loggerInterface LoggerInterface) error + type AbsComponent interface + Start func() + type ApolloConfig struct + Configurations map[string]string + type ApolloConnConfig struct + AppId string + Cluster string + NamespaceName string + ReleaseKey string + type AppConfig struct + AppId string + BackupConfigPath string + Cluster string + Ip string + NamespaceName string + NextTryConnTime int64 + func GetAppConfig(newAppConfig *AppConfig) *AppConfig + type CallBack struct + NotModifyCallBack func() error + SuccessCallBack func([]byte) (interface{}, error) + type ChangeEvent struct + Changes map[string]*ConfigChange + Namespace string + type ChangeListener interface + OnChange func(event *ChangeEvent) + type Config struct + func GetConfig(namespace string) *Config + func GetConfigAndInit(namespace string) *Config + func (c *Config) GetContent(format ConfigFileFormat) string + func (this *Config) GetBoolValue(key string, defaultValue bool) bool + func (this *Config) GetFloatValue(key string, defaultValue float64) float64 + func (this *Config) GetIntValue(key string, defaultValue int) int + func (this *Config) GetStringValue(key string, defaultValue string) string + type ConfigChange struct + ChangeType ConfigChangeType + NewValue string + OldValue string + type ConfigChangeType int + const ADDED + const DELETED + const MODIFIED + type ConfigFileFormat string + const JSON + const Properties + const XML + const YAML + const YML + type ConnectConfig struct + Timeout time.Duration + Uri string + type ContentParser interface + type DefaultLogger struct + func (this *DefaultLogger) Debug(v ...interface{}) + func (this *DefaultLogger) Debugf(format string, params ...interface{}) + func (this *DefaultLogger) Error(v ...interface{}) error + func (this *DefaultLogger) Errorf(format string, params ...interface{}) error + func (this *DefaultLogger) Info(v ...interface{}) + func (this *DefaultLogger) Infof(format string, params ...interface{}) + func (this *DefaultLogger) Warn(v ...interface{}) error + func (this *DefaultLogger) Warnf(format string, params ...interface{}) error + type DefaultParser struct + type LoggerInterface interface + Debug func(v ...interface{}) + Debugf func(format string, params ...interface{}) + Error func(v ...interface{}) error + Errorf func(format string, params ...interface{}) error + Info func(v ...interface{}) + Infof func(format string, params ...interface{}) + Warn func(v ...interface{}) error + Warnf func(format string, params ...interface{}) error + type NotifyConfigComponent struct + func (this *NotifyConfigComponent) Start() + type PropertiesParser struct Other modules containing this package github.com/iammeizu/agollo