You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2019/10/24 06:47:02 UTC

[dubbo] branch 2.7.4-release updated: Postpone checkSubConfig logic in ReferenceConfig (#5226)

This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch 2.7.4-release
in repository https://gitbox.apache.org/repos/asf/dubbo.git


The following commit(s) were added to refs/heads/2.7.4-release by this push:
     new b4b63d3  Postpone checkSubConfig logic in ReferenceConfig (#5226)
b4b63d3 is described below

commit b4b63d36557ec16321dd6bae554ab3dac43ab0f9
Author: violin <gu...@ctrip.com>
AuthorDate: Thu Oct 24 14:46:51 2019 +0800

    Postpone checkSubConfig logic in ReferenceConfig (#5226)
---
 .../src/main/java/org/apache/dubbo/config/ReferenceConfig.java         | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/ReferenceConfig.java b/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/ReferenceConfig.java
index ae1c40f..1aefec3 100644
--- a/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/ReferenceConfig.java
+++ b/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/ReferenceConfig.java
@@ -241,12 +241,11 @@ public class ReferenceConfig<T> extends AbstractReferenceConfig {
     }
 
     public synchronized T get() {
-        checkAndUpdateSubConfigs();
-
         if (destroyed) {
             throw new IllegalStateException("The invoker of ReferenceConfig(" + url + ") has already destroyed!");
         }
         if (ref == null) {
+            checkAndUpdateSubConfigs();
             init();
         }
         return ref;