Skip to content
Snippets Groups Projects
Commit 2c5a4f60 authored by 邹毅贤's avatar 邹毅贤
Browse files

fix zookeeper config center namespace default value invalid

parent 932e1495
No related branches found
No related tags found
No related merge requests found
...@@ -40,7 +40,7 @@ type ConfigCenterConfig struct { ...@@ -40,7 +40,7 @@ type ConfigCenterConfig struct {
Username string `yaml:"username" json:"username,omitempty"` Username string `yaml:"username" json:"username,omitempty"`
Password string `yaml:"password" json:"password,omitempty"` Password string `yaml:"password" json:"password,omitempty"`
ConfigFile string `default:"dubbo.properties" yaml:"config_file" json:"config_file,omitempty"` ConfigFile string `default:"dubbo.properties" yaml:"config_file" json:"config_file,omitempty"`
Namespace string `default:"dubbo.properties" yaml:"namespace" json:"namespace,omitempty"` Namespace string `default:"dubbo" yaml:"namespace" json:"namespace,omitempty"`
AppConfigFile string `default:"dubbo.properties" yaml:"app_config_file" json:"app_config_file,omitempty"` AppConfigFile string `default:"dubbo.properties" yaml:"app_config_file" json:"app_config_file,omitempty"`
AppId string `default:"dubbo" yaml:"app_id" json:"app_id,omitempty"` AppId string `default:"dubbo" yaml:"app_id" json:"app_id,omitempty"`
TimeoutStr string `yaml:"timeout" json:"timeout,omitempty"` TimeoutStr string `yaml:"timeout" json:"timeout,omitempty"`
......
...@@ -58,7 +58,7 @@ func newApolloConfiguration(url *common.URL) (*apolloConfiguration, error) { ...@@ -58,7 +58,7 @@ func newApolloConfiguration(url *common.URL) (*apolloConfiguration, error) {
configCluster := url.GetParam(constant.CONFIG_CLUSTER_KEY, "") configCluster := url.GetParam(constant.CONFIG_CLUSTER_KEY, "")
appId := url.GetParam(constant.CONFIG_APP_ID_KEY, "") appId := url.GetParam(constant.CONFIG_APP_ID_KEY, "")
namespaces := url.GetParam(constant.CONFIG_NAMESPACE_KEY, getProperties(DEFAULT_GROUP)) namespaces := getProperties(url.GetParam(constant.CONFIG_NAMESPACE_KEY, DEFAULT_GROUP))
c.appConf = &agollo.AppConfig{ c.appConf = &agollo.AppConfig{
AppId: appId, AppId: appId,
Cluster: configCluster, Cluster: configCluster,
......
...@@ -192,7 +192,7 @@ func initMockApollo(t *testing.T) *apolloConfiguration { ...@@ -192,7 +192,7 @@ func initMockApollo(t *testing.T) *apolloConfiguration {
Address: "106.12.25.204:8080", Address: "106.12.25.204:8080",
AppId: "testApplication_yang", AppId: "testApplication_yang",
Cluster: "dev", Cluster: "dev",
Namespace: "mockDubbog.properties", Namespace: "mockDubbog",
}} }}
apollo := initApollo() apollo := initApollo()
apolloUrl := strings.ReplaceAll(apollo.URL, "http", "apollo") apolloUrl := strings.ReplaceAll(apollo.URL, "http", "apollo")
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment