Hi, i use Intellij since 5 days, and it looks pretty good. So i created a new java project and use log4j2, easy business, everything works fine. Then i created an artifact for easy deployment. The problem, i'am not able to run / execute the artifact JAR file! I get the error, taht the log4j.xml is missing:
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/logging/log4j/LogManager
at iBox.IBox.<init>(IBox.java:64)
at iboxapp.Start.main(Start.java:28)
Caused by: java.lang.ClassNotFoundException: org.apache.logging.log4j.LogManager
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
Log4j.xml is part of the artifact (JAR file). Where is the correct location for the xml file?! I don't use Maven, Intellij 2017.2
Any ideas?!
Thx
The problem was a mix of old and new log4j references. After cleanup, everything works fine. THX