0

So I have a third party library that uses log4j 2.x . I would like to instead route those log4j 2.x calls to SLF4J so they can use my application log implementation which is logback.

As described here Is there an adapter for log4j2 to work over slf4j?

The flow should go like

It should go third party library uses log4j-api-2.x.jar
->
Slf4j Bridge lof4j-to-slf4j-2x.jar
-> 
Sl4j.api.jar
->
My applications logback

However when I import log4j-api and log4j-to-slf4j:2.16.0 I can see that my third party library has errors when using the org.apache.logging.log4j.core.* classes? It seems like they are part of the core log4j library, which is an implemenation of log4j 2.x, which I do not want to use. I just want the log4j calls to be routed to SLF4J

hello2244
  • 49
  • 3

0 Answers0