Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

register not use metadata configuration. #1565

Merged
merged 7 commits into from
Nov 10, 2021

Conversation

binbin0325
Copy link
Member

What this PR does:
1:service register not use metadata configuration.
2:metadata-type=local , metadata information will not be uploaded to the configuration center
Which issue(s) this PR fixes:
Fixes :#1544

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

Metadata is not used to configure information about the registry during registration

@binbin0325 binbin0325 force-pushed the 20211102_nacos branch 2 times, most recently from 420814a to 707df34 Compare November 6, 2021 09:56
@binbin0325 binbin0325 force-pushed the 20211102_nacos branch 3 times, most recently from 67ff14a to 6ad5a32 Compare November 7, 2021 05:42
@codecov-commenter
Copy link

codecov-commenter commented Nov 7, 2021

Codecov Report

Merging #1565 (001f95c) into 3.0 (eb6010c) will decrease coverage by 0.05%.
The diff coverage is 49.37%.

Impacted file tree graph

@@            Coverage Diff             @@
##              3.0    #1565      +/-   ##
==========================================
- Coverage   41.81%   41.75%   -0.06%     
==========================================
  Files         258      258              
  Lines       15117    15137      +20     
==========================================
  Hits         6321     6321              
- Misses       8055     8077      +22     
+ Partials      741      739       -2     
Impacted Files Coverage Δ
cluster/router/v3router/router_chain.go 41.80% <0.00%> (ø)
common/extension/service_discovery.go 0.00% <0.00%> (ø)
config/metadata_report_config.go 22.78% <0.00%> (-0.60%) ⬇️
config/reference_config.go 0.00% <0.00%> (ø)
metadata/service/local/service.go 73.52% <0.00%> (-0.55%) ⬇️
metadata/service/local/service_proxy.go 63.09% <0.00%> (-0.77%) ⬇️
protocol/dubbo/dubbo_protocol.go 1.98% <0.00%> (ø)
registry/base_registry.go 1.22% <0.00%> (ø)
registry/etcdv3/service_discovery.go 1.34% <0.00%> (+0.03%) ⬆️
...gistry/event/protocol_ports_metadata_customizer.go 10.81% <0.00%> (ø)
... and 43 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update eb6010c...001f95c. Read the comment docs.

@LaurenceLiZhixin
Copy link
Contributor

Thanks for your contribution, I'll test it locally to confirm soon.

@Mulavar
Copy link
Member

Mulavar commented Nov 8, 2021

mark:该 pr 也修复了 #1573

common.WithParams(url.GetParams()),
common.WithParamsValue(constant.NacosUsername, url.Username),
common.WithParamsValue(constant.NacosPassword, url.Password),
common.WithParamsValue(constant.NacosNamespaceID, url.GetParam(constant.NamespaceKey, "")))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

还有一个问题,假如用户没设置 namespace,在 config_center_config.go 里,给这个字段设置了一个默认值 dubbo,所以 url.GetParam(constant.NamespaceKey, "") 这个代码应该永远不会返回 "",需要改一下 namespace 在 config_center_config.go 的默认值。

@LaurenceLiZhixin
Copy link
Contributor

LaurenceLiZhixin commented Nov 10, 2021

@Mulavar
#1565 (comment)
我删除了默认值,在samples 已经修改 见 apache/dubbo-go-samples#293
nacos 默认值为DEFAULT_GROUP,zk默认值为dubbo,由对应实现自己决定。
已经按照这个逻辑改好了,ci通过了。

@zhaoyunxing92 zhaoyunxing92 merged commit 0c85c55 into apache:3.0 Nov 10, 2021
@zhaoyunxing92 zhaoyunxing92 added this to the v3.0.0 milestone Nov 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants