logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jochen Wiedmann <jochen.wiedm...@gmail.com>
Subject Programmatic configuration => NPE
Date Thu, 09 Jun 2016 11:09:13 GMT
Hi,

what is wrong with the following code, please (gives an NPE within
getLogger, MyConfigurationFactory is never being invoked).

    public static void main(String[] pArgs) {
        ConfigurationFactory.setConfigurationFactory(new
MyConfigurationFactory());
        final Logger log = LogManager.getLogger(Main.class);
        log.info("Starting");
    }

Thanks,

Jochen

-- 
The next time you hear: "Don't reinvent the wheel!"

http://www.keystonedevelopment.co.uk/wp-content/uploads/2014/10/evolution-of-the-wheel-300x85.jpg

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message