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

laurence pushed a commit to branch revert-1304-feature/add_lock
in repository https://gitbox.apache.org/repos/asf/dubbo-go.git

commit 53f1f7a27418817d8fe0ac5741ef155e3ef9ecc6
Author: Laurence <[email protected]>
AuthorDate: Sun Jul 18 15:10:48 2021 +0800

    Revert "add lock (#1304)"
    
    This reverts commit a10996763e3e1ffa5cdbd80cb49319a4e3626994.
---
 config/config_loader.go | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/config/config_loader.go b/config/config_loader.go
index 20d5cf1..9fc7da4 100644
--- a/config/config_loader.go
+++ b/config/config_loader.go
@@ -451,8 +451,6 @@ func GetApplicationConfig() *ApplicationConfig {
 // if not found, create new one
 func GetProviderConfig() ProviderConfig {
        if providerConfig == nil {
-               configAccessMutex.Lock()
-               defer configAccessMutex.Unlock()
                if providerConfig == nil {
                        return ProviderConfig{}
                }
@@ -467,8 +465,6 @@ func GetProviderConfig() ProviderConfig {
 // So you don't need to worry about the race condition
 func GetConsumerConfig() ConsumerConfig {
        if consumerConfig == nil {
-               configAccessMutex.Lock()
-               defer configAccessMutex.Unlock()
                if consumerConfig == nil {
                        return ConsumerConfig{}
                }

Reply via email to