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 2018/07/29 09:51:10 UTC

[GitHub] solid210 opened a new pull request #2150: Fixes #478.

solid210 opened a new pull request #2150: Fixes #478.
URL: https://github.com/apache/incubator-dubbo/pull/2150
 
 
   1. Delete zk node when invoke ReferenceConfig.destory() which consumer uses ZookeeperRegistry.
   2. Remove ConcurrentMap<NotifyListener, ChildListener> in zkListeners if the map is empty(release the memory).
   
   
   ## What is the purpose of the change
   [Issues-487] Fix 487.
   
   
   ## Brief changelog
   1. Delete zk node when invoke ReferenceConfig.destory() which consumer uses ZookeeperRegistry.
   2. Remove ConcurrentMap<NotifyListener, ChildListener> in zkListeners if the map is empty(release the memory).
   
   
   ## Verifying this change
   
   **1. How to verify zookeeper node?** 
   Prepare: 
   - Startup a zookeeper application.
   - Create an simple dubbo provider in an application, use zookeeper registry.
   - Create an simple dubbo consumer in another application, use zookeeper registry.
   - Startup dubbo-admin to monitor provider and consumer node. 
   Before using this commit:
   1. Create a ReferenceConfig with GenericService in consumer application and use the GenericService to  invoke any method of the provider.
   2. Use any browser to open dubbo-admin page and switch to "consumer" tab, you can see there is a consumer data.
   3. Invoke  ReferenceConfig#destroy() method, then flush page of dubbo-admin.
   4. You can see the consumer data still exist (because zk node still exist).
   After using this commit:
   Do same operations 1, 2 and 3 above.
   4. You can see the consumer data is removed (zk node is removed.).
   
   **2. How to verify zkListener?**
   There is a JUnit Test to verify zkListener

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


With regards,
Apache Git Services

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