首页 > 代码库 > log4j.properties
log4j.properties
### set log levels ### log4j.rootLogger = INFO, stdout , D , E ### \u8F93\u51FA\u5230\u63A7\u5236\u53F0 ### log4j.appender.stdout = org.apache.log4j.ConsoleAppender log4j.appender.stdout.Threshold = Debug log4j.appender.stdout.Target = System.out log4j.appender.stdout.layout = org.apache.log4j.PatternLayout log4j.appender.stdout.layout.ConversionPattern = %d{ABSOLUTE} %5p %c{1}:%L - %m%n ### \u8F93\u51FA\u5230\u65E5\u5FD7\u6587\u4EF6 ### log4j.appender.D = org.apache.log4j.DailyRollingFileAppender log4j.appender.D.Encoding=UTF-8 log4j.appender.D.File = ${LOG_DIR}/log/log.html ##log4j.appender.D.File = null/log/log.log log4j.appender.D.Append = true log4j.appender.D.Threshold = Debug ## \u8F93\u51FADEBUG\u7EA7\u522B\u4EE5\u4E0A\u7684\u65E5\u5FD7 ## log4j.appender.D.layout = com.core.HtmlLogFormat #log4j.appender.D.layout = org.apache.log4j.HTMLLayout ##log4j.appender.D.layout = org.apache.log4j.PatternLayout ##log4j.appender.D.layout.ConversionPattern = %-d{yyyy-MM-dd HH:mm:ss} [ %t:%r ] - [ %p ] %m%n ### \u4FDD\u5B58\u5F02\u5E38\u4FE1\u606F\u5230\u5355\u72EC\u6587\u4EF6 ### log4j.appender.E = org.apache.log4j.DailyRollingFileAppender log4j.appender.E.File = ${LOG_DIR}/log/error.log ##log4j.appender.E.File = null/log/error.log ## \u5F02\u5E38\u65E5\u5FD7\u6587\u4EF6\u540D ## log4j.appender.E.Append = true log4j.appender.E.Threshold = ERROR ## \u53EA\u8F93\u51FAERROR\u7EA7\u522B\u4EE5\u4E0A\u7684\u65E5\u5FD7!!! ## log4j.appender.E.layout = org.apache.log4j.PatternLayout log4j.appender.E.layout.ConversionPattern = %-d{yyyy-MM-dd HH:mm:ss} [ %t:%r ] - [ %p ] %m%n
log4j.properties
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。