java.lang.NoClassDefFoundError:org.apache.log4j.Logger

时间:2016-12-13 10:37:39

标签: logging classnotfound

在我有记录器的ejb jar中,我遇到异常@runtime。

java.lang.NoClassDefFoundError: org.apache.log4j.Logger
        at java.lang.Class.getDeclaredFieldsImpl(Native Method)
        at java.lang.Class.getDeclaredFields(Class.java:817)

Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Logger
        at java.net.URLClassLoader.findClass(URLClassLoader.java:600)

Following is the ear structure :
Using WAS8.5 and maven . When the same ear is generated through RAD tool it works fine .

     ear
     |---lib --- log4j.jar
     |---ejb
     |---Meta-INF

0 个答案:

没有答案