Documentation ¶
Index ¶
Constants ¶
View Source
const ( ScopeApplication = "application" GeneralType = "general" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConditionMatch ¶ added in v3.1.1
type ConditionMatch struct { Address *common.AddressMatch `yaml:"address"` ProviderAddress *common.AddressMatch `yaml:"providerAddress"` Service *common.ListStringMatch `yaml:"service"` App *common.ListStringMatch `yaml:"app"` Param []*common.ParamMatch `yaml:"param"` }
type ConfigItem ¶
type ConfigItem struct { Type string `yaml:"type"` Enabled bool `yaml:"enabled"` Addresses []string `yaml:"addresses"` ProviderAddresses []string `yaml:"providerAddresses"` Services []string `yaml:"services"` Applications []string `yaml:"applications"` Parameters map[string]string `yaml:"parameters"` Side string `yaml:"side"` Match *ConditionMatch `yaml:"match"` }
ConfigItem defines config item
type ConfigurationParser ¶
type ConfigurationParser interface { Parse(string) (map[string]string, error) ParseToUrls(content string) ([]*common.URL, error) }
ConfigurationParser interface
type ConfiguratorConfig ¶
type ConfiguratorConfig struct { ConfigVersion string `yaml:"configVersion"` Scope string `yaml:"scope"` Key string `yaml:"key"` Enabled bool `yaml:"enabled"` Configs []ConfigItem `yaml:"configs"` }
ConfiguratorConfig defines configurator config
type DefaultConfigurationParser ¶
type DefaultConfigurationParser struct{}
DefaultConfigurationParser for supporting properties file in config center
func (*DefaultConfigurationParser) Parse ¶
func (parser *DefaultConfigurationParser) Parse(content string) (map[string]string, error)
Parse load content
func (*DefaultConfigurationParser) ParseToUrls ¶
func (parser *DefaultConfigurationParser) ParseToUrls(content string) ([]*common.URL, error)
ParseToUrls is used to parse content to urls
Click to show internal directories.
Click to hide internal directories.