You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2022/08/09 07:30:34 UTC

[GitHub] [dubbo] xh1202 opened a new issue, #10426: Dubbo 3.0分支NacosMetadataReport 中 mapping 监听器无法正常移除

xh1202 opened a new issue, #10426:
URL: https://github.com/apache/dubbo/issues/10426

   问题描述:NacosMetadataReport#getServiceAppMapping 方法将监听器存入casListenerMap中,key是使用 DEFAULT_MAPPING_GROUP
   作为group构建;但是 NacosMetadataReport#removeServiceAppMappingListener方法中,移除监听器时使用group不是 DEFAULT_MAPPING_GROUP,从而导致无法正常移除监听器
   
   ~~~
   @Override
       public Set<String> getServiceAppMapping(String serviceKey, MappingListener listener, URL url) {
           String group = DEFAULT_MAPPING_GROUP;
   
           if (null == casListenerMap.get(buildListenerKey(serviceKey, group))) {
               addCasServiceMappingListener(serviceKey, group, listener);
           }
           String content = getConfig(serviceKey, group);
           return ServiceNameMapping.getAppNames(content);
       }
   
       @Override
       public void removeServiceAppMappingListener(String serviceKey, MappingListener listener) {
           MappingDataListener mappingDataListener = casListenerMap.get(buildListenerKey(serviceKey, group));
           if (null != mappingDataListener) {
               removeCasServiceMappingListener(serviceKey, group, listener);
           }
       }
   ~~~


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] AlbumenJ closed issue #10426: Dubbo 3.0分支NacosMetadataReport 中 mapping 监听器无法正常移除

Posted by GitBox <gi...@apache.org>.
AlbumenJ closed issue #10426: Dubbo 3.0分支NacosMetadataReport 中 mapping 监听器无法正常移除
URL: https://github.com/apache/dubbo/issues/10426


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] xh1202 commented on issue #10426: Dubbo 3.0分支NacosMetadataReport 中 mapping 监听器无法正常移除

Posted by GitBox <gi...@apache.org>.
xh1202 commented on issue #10426:
URL: https://github.com/apache/dubbo/issues/10426#issuecomment-1210640823

   I am waiting for a confirmation reply and then go to fix it .....


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org