NutzCN Logo
短点 log4j 的问题麻烦兽总帮看看_92265c83
发布于 3147天前 作者 明天会吹什么风 1706 次浏览 复制 上一个帖子 下一个帖子
标签:

查看完整内容

信息如下:
ALL Nutz Log via Log4jLogAdapter
log4j:ERROR Could not find value for key log4j.appender.error
log4j:ERROR Could not instantiate appender named "error".



log4j.properties 代码如下:

#Tomcat and third party Logger
log4j.rootLogger=debug,CONSOLE,info,error
log4j.category.org.nutz=debug,CONSOLE

log4j.additivity.org.stdout=true

#Appenders ...
log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
log4j.appender.CONSOLE.layout.ConversionPattern=%d [%t] %-5p %c - %m%n

log4j.logger.info=info
log4j.appender.info=org.apache.log4j.DailyRollingFileAppender
log4j.appender.info.layout=org.apache.log4j.PatternLayout
log4j.appender.info.layout.ConversionPattern=%d{yyyy-MM-dd HH\:mm\:ss,SSS} %5p %c{1}\:%L - %m%n
log4j.appender.info.Threshold=INFO
log4j.appender.info.append=true
log4j.appender.info.File=/opt/log/info/info.log 

log4j.logger.cn.guagua.mobile.common.LogInterceptor=debug,debug

log4j.logger.debug=debug
log4j.appender.debug=org.apache.log4j.DailyRollingFileAppender
log4j.appender.debug.layout=org.apache.log4j.PatternLayout
log4j.appender.debug.layout.ConversionPattern=%d{yyyy-MM-dd HH\:mm\:ss,SSS} %5p %c{1}\:%L - %m%n
log4j.appender.debug.Threshold=DEBUG
log4j.appender.debug.append=true
log4j.appender.debug.File=/opt/log/debug/debug.log

log4j.logger.cn.guagua.mobile.common.ErrMsgView=error,error

log4j.logger.ERROR=error
log4j.appender.ERROR=org.apache.log4j.DailyRollingFileAppender
log4j.appender.ERROR.layout=org.apache.log4j.PatternLayout
log4j.appender.ERROR.layout.ConversionPattern=%d{yyyy-MM-dd HH\:mm\:ss,SSS} %5p %c{1}\:%L - %m%n
log4j.appender.ERROR.Threshold=ERROR
log4j.appender.ERROR.append=true
log4j.appender.ERROR.File=/opt/log/error/error.log

0 回复
添加回复
请先登陆
回到顶部