[ 
https://issues.apache.org/jira/browse/LOGGING-135?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13553623#comment-13553623
 ] 

Thomas Neidhart commented on LOGGING-135:
-----------------------------------------

I do not think the respective logger will be created multiple times, but 
retrieved from the underlying logging system.
In case the underlying system is flawed (e.g. not returning the same instance 
everytime it is called with the same name), this may create problems in the 
commons-logging wrapper, but otherwise the synchronisation may be a bottleneck.

This only relates to the logger fields, SimpleLog may be a different case.
                
> Thread-safety improvements
> --------------------------
>
>                 Key: LOGGING-135
>                 URL: https://issues.apache.org/jira/browse/LOGGING-135
>             Project: Commons Logging
>          Issue Type: Bug
>            Reporter: Sebb
>
> The LogKitLogger.logger field is not final or volatile so changes are not 
> guaranteed to be published.
> This includes calls to getLogger(), so two different threads using the same 
> instance can theoretically both create the logger.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to