diff --git a/config/config_loader.go b/config/config_loader.go index 745dbd85e3..039d8fccb6 100644 --- a/config/config_loader.go +++ b/config/config_loader.go @@ -441,8 +441,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{} } @@ -457,8 +455,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{} }