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 2021/06/18 20:54:19 UTC

[GitHub] [dubbo] caofei88 opened a new issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

caofei88 opened a new issue #8097:
URL: https://github.com/apache/dubbo/issues/8097


   背景:provider起两个服务,使用parameters参数,consumer中去订阅,发现在Directory拿到List<Invoker<T>>与nacos注册中心不一致
   问题定位代码在类DubboCloudRegistry  154行 方法subscribeURLs里面调用
   172的这行代码有问题:
      List<URL> subscribedURLs = this.cloneExportedURLs(subscribedURL, serviceInstances);
   拿到的url对象跟nacos中metadata信息不一致,  多次debug执行会产生不一样的结果 (dubbo 2.7.6 2.7.8同样存在)
   
   demo地址见:git@github.com:caofei88/dubbo-spring-cloud-demo.git
   
    部分provider配置
     provider:                                      
       filter: tracing
       parameters:
         dcCode: "dcCode1"         
    
     provider:
       filter: tracing
       parameters:
         dcCode: "dcCode2"


-- 
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.

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 commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   `DubboCloudRegistry` is in SCA. 
   If you use ServiceDiscovery, it is true that parameters not the same in Nacos. ServiceDiscovery will use MetadataService to fetch real URLs.


-- 
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.

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] CrazyHZM closed issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

Posted by GitBox <gi...@apache.org>.
CrazyHZM closed issue #8097:
URL: https://github.com/apache/dubbo/issues/8097


   


-- 
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] icankeep commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   I'll take a look at this demo


-- 
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.

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] icankeep removed a comment on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

Posted by GitBox <gi...@apache.org>.
icankeep removed a comment on issue #8097:
URL: https://github.com/apache/dubbo/issues/8097#issuecomment-864341720


   I'll take a look at this demo


-- 
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.

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] caofei88 edited a comment on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

Posted by GitBox <gi...@apache.org>.
caofei88 edited a comment on issue #8097:
URL: https://github.com/apache/dubbo/issues/8097#issuecomment-864688404


   > `DubboCloudRegistry` is in SCA.
   > If you use ServiceDiscovery, it is true that parameters not the same in Nacos. ServiceDiscovery will use MetadataService to fetch real URLs.
   
   > `
   ![image](https://user-images.githubusercontent.com/64238311/122701634-43331480-d280-11eb-969a-b50e72fda14f.png)
   ![image](https://user-images.githubusercontent.com/64238311/122701650-4a5a2280-d280-11eb-95ef-e12840add870.png)
   `上面是nacos注册元数据和代码debug截图,请看下


-- 
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.

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] caofei88 commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   这个bug还是比较严重,希望社区有同学尽快跟踪验证并完成修复


-- 
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.

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] CrazyHZM commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   See the above reply has been resolved, temporarily close this issue
   @caofei88 


-- 
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] theonefx commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   你好,我是 sca 这边的同学,你反馈的这个问题之前确实是存在的。
   之前的逻辑,是为了提升效率,直接使用clone的方式来创建新的 URL。
   在之前的实现中,认为同一个应用的同一个接口,除了ip和端口其他都应该是一致的。这就导致了你现在碰到的这个问题。
   
   最新的实现,参照了 dubbo3 的 revision 机制,会对所有提供的服务计算一个版本号,不再单独使用应用名做分组。应该是能解决这个问题的。
   
   最新的代码已经包含了这部分逻辑,正式版本最近会发布,目前你可以使用 2.2.6-bugfix5-SNAPSHOT 试一下。
   期待你的答复。


-- 
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.

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] caofei88 commented on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

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


   > `DubboCloudRegistry` is in SCA.
   > If you use ServiceDiscovery, it is true that parameters not the same in Nacos. ServiceDiscovery will use MetadataService to fetch real URLs.
   
   > `
   ![image](https://user-images.githubusercontent.com/64238311/122701634-43331480-d280-11eb-969a-b50e72fda14f.png)
   ![image](https://user-images.githubusercontent.com/64238311/122701650-4a5a2280-d280-11eb-95ef-e12840add870.png)
   `


-- 
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.

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] caofei88 edited a comment on issue #8097: dubbo2.7.11自定义负载loadBalance,使用provider中parameters参数标签,发现consumer中Directory拿到List>与nacos注册中心不一致

Posted by GitBox <gi...@apache.org>.
caofei88 edited a comment on issue #8097:
URL: https://github.com/apache/dubbo/issues/8097#issuecomment-864688404


   > `DubboCloudRegistry` is in SCA.
   > If you use ServiceDiscovery, it is true that parameters not the same in Nacos. ServiceDiscovery will use MetadataService to fetch real URLs.
   
   > `
   ![image](https://user-images.githubusercontent.com/64238311/122701634-43331480-d280-11eb-969a-b50e72fda14f.png)
   ![image](https://user-images.githubusercontent.com/64238311/122701650-4a5a2280-d280-11eb-95ef-e12840add870.png)
   ![image](https://user-images.githubusercontent.com/64238311/122701802-9b6a1680-d280-11eb-9fb6-1feb0cd8cb00.png)
   ![image](https://user-images.githubusercontent.com/64238311/122701824-a45ae800-d280-11eb-8bbf-8fd410b49cc6.png)
   
   `上面是nacos注册元数据和代码debug截图,请看下


-- 
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.

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