zrlw commented on issue #9239:
URL: https://github.com/apache/dubbo/issues/9239#issuecomment-964884504


   dubbo-samples的dubbo-samples-applevel-override就能稳定重现:
   1. CuratorZookeeperClient的344行设置断点
   ```
               } else if (childData.getStat().getVersion() == 0) {
                   content = new String(childData.getData(), CHARSET);
                   eventType = EventType.NodeCreated;  <== line 344 set 
breakpoint here
               } else {
   ```
   2. 启动zk服务,端口2181
   3. debug启动BasicProvider, 启动参数加dubbo.port=20880
   4. debug启动BasicProvider, 启动参数加dubbo.port=20881
   5. 在ZKTools的66行设置断点:
   ```
               if (client.checkExists().forPath(path) == null) {
                   
client.create().creatingParentsIfNeeded().withMode(CreateMode.PERSISTENT).forPath(path);
  <== line 66 set breakpoint
               }
   ```
   6. debug执行DemoServiceIT单元测试
   7. 
到达ZKTools的66行断点处之后开始单步执行,两个provider中的一个会执行到CuratorZookeeperClient的344行断点,查看content内容就会看到里面只有一个ip地址。
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to