RFR: 8023168 - Cleanup LogManager class initialization and LogManager/LoggerContext relationship

Mandy Chung mandy.chung at oracle.com
Fri Sep 6 14:27:45 UTC 2013

On 9/6/2013 12:38 AM, Daniel Fuchs wrote:
> Should this simply call LogManager.getLogManager() unconditionally as
> in getGlobal()?
> I don't think this would be required.
> Maybe we could make checkPermission() static in LogManager?

That's not a bad idea.

> But we might still need to call LogManager.getLogManager() to avoid 
> regression
> in code using Logger.global directly... 

>>  760 final LogManager owner = getOwner();
>>  761             logger.setLogManager(owner);
>> Should this have an assert to ensure logger.manager == null or == owner?
>> We don't expect a Logger to change its owner, do we?  The behavior of 
>> multiple
>> LogManager instances is not specified anyway.
> I am concerned it could introduce regressions in applications that
> use multiple instances of LogManager or subclasses of Logger.
> I agree this is not perfect. Unfortunately I don't see any ideal 
> solution.

Are you concerned even if it's an assert?


More information about the core-libs-dev mailing list