In my case I have a jboss-5.1 which should pull different jboss-log4j.xml, based on their startup call. Unluckily I was unable to find something like the -Dlogging.properties= for xml-files, to supply different xml-files.
In my case I have a jboss-5.1 which should pull different jboss-log4j.xml , based
Share
If I’ve understood your question, you want JBoss not to use the default conf/jboss-log4j.xml file, but use instead another one defined as a property in the start up script. In that case you should:
1) Modify the ConfigurationURL attribute of the Log4jService defined in the file conf/jboss-service.xml. The original looks like:
Instead you should tell JBoss to take the file from a property (let’s name this property log4j.conf.file, for example), so it would be:
2) And then, start up the JBoss instance defining this property, and setting its value to the exact route of the log4j xml configuration file you want to use for this instance. For example, if the route to this file is “/app/jboss/logconf/log4j.xml“: