Home > General > Log4j Exception while reloading the application in JBoss 5

Log4j Exception while reloading the application in JBoss 5

September 21, 2011

[20 Sep 11 01:52:47,779|STDERR|http-0.0.0.0-8080-5]log4j:ERROR A “org.jboss.logging.appender.FileAppender” object is not assignable to a “org.apache.log4j.Appender” variable. [20 Sep 11 01:52:47,780|STDERR|http-0.0.0.0-8080-5]log4j:ERROR The class “org.apache.log4j.Appender” was loaded by [20 Sep 11 01:52:47,780|STDERR|http-0.0.0.0-8080-5]log4j:ERROR [WebappClassLoader [20 Sep 11 01:52:47,780|STDERR|http-0.0.0.0-8080-5]log4j:ERROR “org.jboss.logging.appender.FileAppender” was loaded by [org.jboss.system.server.NoAnnotationURLClassLoader@1bc82e7]. [20 Sep 11 01:52:47,780|STDERR|http-0.0.0.0-8080-5]log4j:ERROR Could not instantiate appender named “FILE”. [20 Sep 11 01:52:47,819|STDOUT|http-0.0.0.0-8080-5]01:52:47,819 ERROR [SpringContext] Context file is not loaded, as Context file is missing.

 

This is due to the conflict occured between the JBoss Log4j and the Log4j in used in the application.

remove Log4j from the war file before deploying.

in the Log4j.properties use Jboss Appenders insted of default log4j Appenders.

JBoss Log4j appenders can be found in conf/jbosslog4j.xml location.

 

 

 

Advertisements
Categories: General
%d bloggers like this: