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

albumenj pushed a commit to branch 3.2
in repository https://gitbox.apache.org/repos/asf/dubbo.git


The following commit(s) were added to refs/heads/3.2 by this push:
     new e6ee6088bf Remove redundant synchronized (#11811)
e6ee6088bf is described below

commit e6ee6088bffec78c25bae6849e28aa0dada2d0c2
Author: kanghailin <[email protected]>
AuthorDate: Mon Mar 13 20:55:41 2023 +0800

    Remove redundant synchronized (#11811)
---
 .../src/main/java/org/apache/dubbo/config/ReferenceConfig.java      | 6 +-----
 1 file changed, 1 insertion(+), 5 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 86796a9139..ad47b82261 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
@@ -228,11 +228,7 @@ public class ReferenceConfig<T> extends 
ReferenceConfigBase<T> {
             // ensure start module, compatible with old api usage
             getScopeModel().getDeployer().start();
 
-            synchronized (this) {
-                if (ref == null) {
-                    init();
-                }
-            }
+            init();
         }
 
         return ref;

Reply via email to