Click here to Skip to main content
15,562,222 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am trying to get only the Info from the log and Exclude all the Warnings can any one help me below is my Log4j property file

What I have tried:

log4j.rootLogger=INFO,CONSOLE,HTML

//  appender
log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender

log4j.appender.HTML=org.apache.log4j.FileAppender

// log file location

log4j.appender.HTML.File=${LogFileLocation}application.html

// layout and pattern
log4j.appender.CONSOLE.Target=System.out
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
log4j.appender.CONSOLE.layout.ConversionPattern= %5p [%t] (%F:%L)- %m%n

log4j.appender.HTML.layout=org.apache.log4j.HTMLLayout
log4j.appender.HTML.layout.Title=Application log
log4j.appender.HTML.layout.LocationInfo=true
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900