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/07/13 06:25:26 UTC

[GitHub] [dubbo] kylixs commented on a change in pull request #8263: Compatible for curator5.

kylixs commented on a change in pull request #8263:
URL: https://github.com/apache/dubbo/pull/8263#discussion_r668461744



##########
File path: dubbo-configcenter/dubbo-configcenter-zookeeper/src/main/java/org/apache/dubbo/configcenter/support/zookeeper/ZookeeperDynamicConfigurationFactory.java
##########
@@ -28,6 +29,12 @@
 
     private ZookeeperTransporter zookeeperTransporter;
 
+    {
+        ZookeeperTransporter extension = ZookeeperTransporter.getExtension();

Review comment:
       It's better to put it into the constructor.

##########
File path: dubbo-metadata/dubbo-metadata-report-zookeeper/src/main/java/org/apache/dubbo/metadata/store/zookeeper/ZookeeperMetadataReportFactory.java
##########
@@ -28,6 +29,12 @@
 
     private ZookeeperTransporter zookeeperTransporter;
 
+    {
+        ZookeeperTransporter extension = ZookeeperTransporter.getExtension();

Review comment:
       It's better to put it into the constructor.

##########
File path: dubbo-registry/dubbo-registry-zookeeper/src/main/java/org/apache/dubbo/registry/zookeeper/ZookeeperRegistryFactory.java
##########
@@ -17,22 +17,24 @@
 package org.apache.dubbo.registry.zookeeper;
 
 import org.apache.dubbo.common.URL;
+import org.apache.dubbo.common.extension.DisableInject;
 import org.apache.dubbo.registry.Registry;
 import org.apache.dubbo.registry.support.AbstractRegistryFactory;
 import org.apache.dubbo.remoting.zookeeper.ZookeeperTransporter;
 
 /**
  * ZookeeperRegistryFactory.
- *
  */
 public class ZookeeperRegistryFactory extends AbstractRegistryFactory {
 
     private ZookeeperTransporter zookeeperTransporter;
 
-    /**
-     * Invisible injection of zookeeper client via IOC/SPI
-     * @param zookeeperTransporter
-     */
+    {
+        ZookeeperTransporter extension = ZookeeperTransporter.getExtension();

Review comment:
       It's better to put it into the constructor.




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