Hello all,
My team uses JBoss AP 4.0.3SP1 as the server that hosts our application. While I was configuring log4j I came accross that problem:
When I add the following command line property:
-D"log4j.configuration=%JBOSS_SERVER_CONFIG_URL%/%PRODUCT%/log4j.xml"
I get the following exception during jboss bootstrap though I include log4j-1.2.13.jar in the jobss lib folder:
java.lang.ClassNotFoundException: org.apache.log4j.xml.DOMConfigurator
After some research I found out that this is because log4j-boot.jar which is used to parse a log4j.properties in the run.jar of jboss.
Whenever I remove log4j-boot.jar from the lib directory I get the following exception:
java.lang.ClassNotFoundException: Unexpected error during load of: org.jboss.logging.appender.DailyRollingFileAppender, msg=org/apache/log4j/DailyRollingFileAppender
I assume that there is a conflict between log4j-boot.jar and the log4j-1.2.13.jar which I use
Do you know how I can resolve that problem?. Don't tell me not to use the
log4j.configuration command argument cause the deployment of the application in JBoss is not like the typical container-like application (It uses an mbean to start the bootstrap of the application of which the classes are deployed in the jboss lib folver within a jar file
(I know ... its really bad!!!))