You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by B Manikandan <ma...@wipro.com> on 2002/02/22 13:56:09 UTC
Urgent - How to send output of different priorities/categories to
different appenders ?
Hi,
I need to send the log messages from different categories to go to
different appenders.If I have a
log4j.rootCategory=DEBUG,console
then any other appender addition for some category is not reflected.
One more functionality that is needed is to send output of a particular
priority of a prticular category to different appenders.I tried the
following,but it does not work.
log4j.category.com.mizuho.rdw.asset.helper.AssetRequestPublisher=DEBUG,assetRequest
log4j.appender.assetRequest=org.apache.log4j.DailyRollingFileAppender
log4j.appender.assetRequest.File=/usr/log/assetRequest.log
log4j.appender.assetRequest.DatePattern='.'yyyy-MM
log4j.appender.assetRequest.Append=false
log4j.appender.assetRequest.layout=org.apache.log4j.PatternLayout
log4j.appender.assetRequest.layout.ConversionPattern=%d{DATE} : %c :
%-5p : %m%n
log4j.rootCategory=DEBUG, console
#----------------------------------------------------------------------------
# console configuration.
#----------------------------------------------------------------------------
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.layout=org.apache.log4j.PatternLayout
log4j.appender.console.layout.ConversionPattern=%d{DATE} : %c : %-5p :
%m%n
TIA,
Mani
DriverManager.setLogStream(???)
Posted by Ali Mesbah <al...@West.NL>.
I am using JDBC in my application.
I was wondering if I could use log4j (a category) to pass to
DriverManager.setLogStream
method to get the log messages from the DriverManager in my log4j log-file. ???
The default is as follows in my application:
DriverManager.setLogStream(System.Out)
thanks,
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>