Thursday, 22 June 2017

Detected both log4j-over-slf4j.jar AND slf4j-log4j12.jar on the class path, preempting StackOverflowError.

I was hitting the same problem when working with Apache tomcat . .


Solution Steps :


  1. Backup your pom.xml somewhere.
  2. Go to your pom.xml and on the bottom tab and click "Dependency Hierarchy" tab. 
  3. From there search for log4j-over-slf4j. 
  4. Exclude all instances of this dependency (right click on the instance and "Exclude Maven Artifact"). After you have no more log4j-over-slf4j appearing save your POM and try to run the program. 
  5. If it still doesn't work then undo the changes you just made and exclude all instances of slf4j-log4j12.


Hopes this will resolve your problem

No comments:

Post a Comment

Spring boot with CORS

CORS (Cross-Origin Resource Sharing) errors occur when a web application running in a browser requests a resource from a different domain or...