First: Do not ask usage questions on the developer list. Usage questions should be asked on the User list.
Second: Your sample config file indeed directs all log events ERROR+ to all appenders, since the threshold parameter only denotes the lowest level to be logged, not the highest. If you want the JDBC levels only be logged to the DATABASE appender, then you should use a LevelRangeFilter (with an upper limit of FATAL) on the other appenders (DEBUGFILE, EXCEPTIONFILE). Heri -----Ursprüngliche Nachricht----- Von: SteveWay2010 [mailto:[email protected]] Gesendet: Freitag, 19. Februar 2010 14:03 An: [email protected] Betreff: Custom Level Logging to All Appenders Hi Everyone, I have created a Logging Level which is higher than FATAL as I will always want it to be logged amongst a number of other things. So my level is JDBC which is specified as a static final int JDBC = Level.FATAL +1; My Code calls a custom logger (Called "OSOD") and the logging is controlled through this. The problem is, That no matter how my log4.xml file is configured, It logs to EVERY appender. Attached is my log4j.xml config. http://old.nabble.com/file/p27652587/log4j.xml log4j.xml Any help would be greatly appreciated. Many Thanks, Steve -- View this message in context: http://old.nabble.com/Custom-Level-Logging-to-All-Appenders-tp27652587p27652587.html Sent from the Log4j - Dev mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
