
13 May
2009
13 May
'09
6:14 p.m.
You have slf4j-log4j12.jar, logback-classic.jar and slf4j-simple.jar on your classpath - that's three separate SLF4J implementations. You should have only one (logback-classic, presumably). It's initialising SLF4J Simple, so when you retrieve the SLF4J LoggerFactory it's returning an org.slf4j.impl.SimpleLoggerFactory which you then try and cast to ch.qos.lobgack.LoggerFactory, which naturally fails. Take slf4j-log4j12.jar and slf4j-simple.jar off your classpath - if you are trying to redirect log4j to slf4j then you need log4j-over- slf4j.jar, not slf4j-log4j12.jar which instead uses log4j as the slf4j implementation.