File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JBoss/WildFly and the fly likes log4j messages in JBoss log Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "log4j messages in JBoss log" Watch "log4j messages in JBoss log" New topic

log4j messages in JBoss log

Drake Almonto

Joined: Apr 29, 2005
Posts: 16

I am receiving these error messages in the log file during deployment of my application in JBoss. The messages started to appear after I add a log4j jar file to the lib directory in WEB-INF. Can anyone help?

2008-05-14 12:42:17,240 ERROR [STDERR] log4j:ERROR A "org.jboss.logging.appender.FileAppender" object is not assignable to a "org.apache.log4j.Appender" variable.
2008-05-14 12:42:17,240 ERROR [STDERR] log4j:ERROR The class "org.apache.log4j.Appender" was loaded by
2008-05-14 12:42:17,240 ERROR [STDERR] log4j:ERROR [WebappClassLoader
delegate: false
----------> Parent Classloader:
] whereas object of type
2008-05-14 12:42:17,240 ERROR [STDERR] log4j:ERROR "org.jboss.logging.appender.FileAppender" was loaded by [org.jboss.system.server.NoAnnotationURLClassLoader@1e4457d].
2008-05-14 12:42:17,240 ERROR [STDERR] log4j:ERROR Could not instantiate appender named "FILE".
Peter Johnson

Joined: May 14, 2008
Posts: 5852

Remove the log4j.jar file from WEB-INF/lib. JBossAS already has that file, so you don't need it. And as you found it causes classloader issues if you have your own copy.

JBoss In Action
I agree. Here's the link:
subject: log4j messages in JBoss log
It's not a secret anymore!