We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
NacosServiceMapping的初始化逻辑注入Url为metadataUrl,参考代码ConfigServer.getServiceMapping(ServiceDiscovery serviceDiscovery, InstanceRegistryCache instanceRegistryCache) 而目前按照Dubbo的处理逻辑,metadataUrl的group默认值为dubbo、registryUrl的group默认值为DEFAULT_GROUP,即存在metadataUrl与registryUrl不一致的情况,此时NacosServiceMapping使用metadataUrl初始化则导致getAllServiceNames()结果为空,现象为管理界面服务列表为空,此处应该修改为使用registryUrl进行初始化,才能使服务列表正常获取和显示,参考如下
@Bean @DependsOn("dubboRegistry") ServiceMapping getServiceMapping(ServiceDiscovery serviceDiscovery, InstanceRegistryCache instanceRegistryCache) { ServiceMapping serviceMapping = new NoOpServiceMapping(); if (registryUrl == null) { return serviceMapping; } MappingListener mappingListener = new AdminMappingListener(serviceDiscovery, instanceRegistryCache); serviceMapping = ExtensionLoader.getExtensionLoader(ServiceMapping.class).getExtension(registryUrl.getProtocol()); serviceMapping.addMappingListener(mappingListener); serviceMapping.init(registryUrl); return serviceMapping; }
The text was updated successfully, but these errors were encountered:
#1148
Sorry, something went wrong.
ServiceMapping
No branches or pull requests
Environment
Steps to reproduce this issue
NacosServiceMapping的初始化逻辑注入Url为metadataUrl,参考代码ConfigServer.getServiceMapping(ServiceDiscovery serviceDiscovery, InstanceRegistryCache instanceRegistryCache)
而目前按照Dubbo的处理逻辑,metadataUrl的group默认值为dubbo、registryUrl的group默认值为DEFAULT_GROUP,即存在metadataUrl与registryUrl不一致的情况,此时NacosServiceMapping使用metadataUrl初始化则导致getAllServiceNames()结果为空,现象为管理界面服务列表为空,此处应该修改为使用registryUrl进行初始化,才能使服务列表正常获取和显示,参考如下
The text was updated successfully, but these errors were encountered: