Source Code‎ > ‎src‎ > ‎

log4j.properties

### direct log messages to stdout ###
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Target=System.out
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d{dd MM yy HH:mm:ss} %5p %c{1}:%L - %m%n

### direct messages to file hibernate.log ###
log4j.appender.file=org.apache.log4j.DailyRollingFileAppender
log4j.appender.file.File=D:/log4j.txt
log4j.appender.file.DatePattern='.'yyyy-MM-dd
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d{dd MM yy HH:mm:ss} %5p %c{1}:%L - %m%n

### set log category - debug,info,warn,error,fatal

#log4j.rootLogger=warn,file
log4j.rootLogger=debug,file,stdout
Comments