Details
-
Improvement
-
Resolution: Incomplete
-
None
-
1.6.x
-
None
-
Operating System: Windows NT
Platform: PC
-
enhancement
-
P2
-
202
Description
the log4j-over-slf4j bridge doesn't implement the xml package of the underlying log4j library.
This causes an error in the bindings that is results in a NoSuchMethodError run time error.
the xml.DOMConfigurator class makes reference to the LogManager class. Since the LogManager class is bound to the slf4j implementation, which does not implement the getLoggerRepository() method, an error ensues.
java.lang.NoSuchMethodError: org.apache.log4j.LogManager.getLoggerRepository()Lorg/apache/log4j/spi/LoggerRepository;
at org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:743) ~[log4j-1.2.14.jar:na]
This can either be fixed by intercepting calls to the DOMConfigurator, or by implementing the getLoggerRepository() method on the LogManager.