[logback-user] breaking on startup

Ceki Gulcu ceki at qos.ch
Wed May 13 13:43:51 CEST 2009


Hello Brian,

Could you please post the two or three lines of the stack trace? Which artifacts 
(jar files) have you placed on the class path?

Brian Moschel wrote:
> Hey guys,
> 
> I am noticing an error on startup:
> 
> java.lang.ClassCastException: org.slf4j.impl.SimpleLoggerFactory
> 
> I am trying to run the following lines to load my config, which I got 
> from the startup guide:
> 
> LoggerContext lc = (LoggerContext) LoggerFactory.getILoggerFactory();
> JoranConfigurator configurator = new JoranConfigurator();
> lc.reset();
> configurator.setContext(lc);
> configurator.doConfigure(my_path);
> StatusPrinter.printInCaseOfErrorsOrWarnings(lc);
> 
> The error occurs at the first line in the above code.  I got this 
> working at some point, but somehow am back in a non-working state.  This 
> is a Jetty app.  Any tips?
> 
> Thanks,
> Brian
-- 
Ceki Gülcü
Logback: The reliable, generic, fast and flexible logging framework for Java.
http://logback.qos.ch


More information about the Logback-user mailing list