On Thu, Jun 9, 2016 at 2:45 PM, Remko Popma <remko.po...@gmail.com> wrote: > Do you have a stacktrace?
Silly me. Of course, I have: Exception in thread "main" java.lang.NullPointerException: No Configuration was provided at java.util.Objects.requireNonNull(Objects.java:228) at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:477) at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:561) at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:577) at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:212) at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:152) at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:45) at org.apache.logging.log4j.LogManager.getContext(LogManager.java:194) at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:551) at demo.log4j.Main.main(Main.java:11) And here's the source code again, if you'd like to reproduce: public static void main(String[] pArgs) { ConfigurationFactory.setConfigurationFactory(new MyConfigurationFactory()); final Logger log = LogManager.getLogger(Main.class); log.info("Starting"); } -- 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-unsubscr...@logging.apache.org For additional commands, e-mail: log4j-user-h...@logging.apache.org