修复 bug:当dubbo接口注册为服务别称时,consumer端找不到可用 provider #30
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
背景: ZooKeeper内注册的dubbo服务同步到Polaris时,把url中的{application}注册为服务,url中的{interface}注册为服务别称。
问题: 当consumer端调用服务时,是把{interface}作为服务从Polaris获取实例;而Polars返回实例的interface仍然是{application},引发“No provider available……” 错误。
解决方案: 从Polaris得到实例列表时,把实例元数据的 interface 直接设置为被调 interface