Hi, I tried to configure Merlin (3.3-RC6) to use log4j for logging, by using the following properties:
merlin.logging.implementation=artifact:avalon-logging/avalon-logging-log4j#1.0.0 merlin.logging.config=log4j.xml These are recognized and it basically works, but I noticed two problems: 1. loggers are retrieved from log4j using slashes as separators in the category name instead of dots, which log4j doesn't recognize. For example, "/a/b" instead of "a.b". This is because getQualifiedName() of DeploymentModel is used for this. 2. Log4jLoggingFactory strips all slashes in front of the configuration file name, which is IMO one too much. I specifiy a relative path (in fact just log4j.xml in the current directory), Merlin turns this into an absolute path, and the Log4jLoggingFactory strips the leading slashes turning it in an incorrect relative path. Eventually log4j finds the file through its fall back mechanisms, you can see that this is the case by doing an "export MERLIN_JVM_OPTS=-Dlog4j.configDebug=true" before starting Merlin, output is: log4j: [home/bruno/<snip>/log4j.xml] does not exist. log4j: Trying to find [log4j.xml] using context classloader [EMAIL PROTECTED] log4j: Trying to find [log4j.xml] using [EMAIL PROTECTED] class loader. log4j: Trying to find [log4j.xml] using ClassLoader.getSystemResource(). log4j: Trying to find [log4j.properties] using context classloader [EMAIL PROTECTED] log4j: Trying to find [log4j.properties] using [EMAIL PROTECTED] class loader. log4j: Trying to find [log4j.properties] using ClassLoader.getSystemResource(). log4j: Could not find resource: [null]. log4j: System property is :null log4j: Standard DocumentBuilderFactory search succeded. log4j: DocumentBuilderFactory is: org.apache.crimson.jaxp.DocumentBuilderFactoryImpl -- Bruno Dumon http://outerthought.org/ Outerthought - Open Source, Java & XML Competence Support Center [EMAIL PROTECTED] [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]