I am running JBoss 3.2.1 combined tomcat 4.1.24 on Linux Redhat 9.0 and having problems with log4j and my own defined log4j Level.
I have a log4j level defined as PERF which I use to get timings out of key points in my application. The PERF debug messages are appearing in the server.log. However when I try and configure an appender to output these messages to a seperate log I get nothing logged out. I am using a LevelMatchFilter within the appender to pullout these messages.
Below is a fragment of the log4j.xml file defining the appender and the category that uses it
<!-- Rollover at midnight each day -->
<param name="DatePattern" value="'.'yyyy-MM-dd"/>
<!-- The default pattern: Date Priority [Category] Message\n -->
I have tried various different ways of defining the value in LevelToMatch such as
<appender-ref ref="PERF"/>
The Perf Level is defined as follows
package com.arena.skylla.core.common.log4jlevels;
import org.apache.log4j.Level;
/**
* @author mitchelln
*
* To change the template for this generated type comment go to
* Window>Preferences>Java>Code Generation>Code and Comments
*/
public class PerfLevel extends Level{
public static int PERF_INT = 25001;
public final static Level PERF = new PerfLevel();
PerfLevel()
{
super(PERF_INT, "PERF", 5);
}
}
Any help on this would be would be great.
Cheers
neil