NutzCN Logo
问答 想问一下怎么把控制台的DEBUG、INFO 信息屏蔽掉
发布于 2774天前 作者 qq_722cb381 2067 次浏览 复制 上一个帖子 下一个帖子
标签:

例如这些

05-19 13:19:24.845  DEBUG - [LoggingMethodInterceptor.localhost-startStop-1] [afterInvoke] Obj = [com.brt.museum.dao.auth.impl.RolePermissionDao$$NUTZAOP] , Return = {"roleId":1,"permissionId":63,"powerTime":"2017-05-08 10:15:55","id":124} , Method = public com.dgj.utils.db.data.Entity com.dgj.utils.db.dao.impl.BaseDao.findByCondition(org.nutz.dao.Condition) , args = [ WHERE p_id=63 AND r_id=1]
05-19 13:19:24.845  DEBUG - [LoggingMethodInterceptor.localhost-startStop-1] [beforeInvoke] Obj = [com.brt.museum.service.auth.impl.PermissionService$$NUTZAOP] , Method = public com.brt.museum.bean.auth.Permission com.brt.museum.service.auth.impl.PermissionService.findByName(java.lang.String) , args = [联盟订单列表]
05-19 13:31:37.252  INFO  - [NutLoading.localhost-startStop-1] Nutz.Mvc[nutz] is up in 3504ms
05-19 13:31:37.252  INFO  - [NutFilter.localhost-startStop-1] exclusionsPrefix  = ^(/resources/)
05-19 13:31:37.253  INFO  - [NutFilter.localhost-startStop-1] exclusionsSuffix = (.ico|.js|.css|.png|.jpg|.gif)$
6 回复

加log4j,然后配log4j.properties

@wendal 我之前配了log4j.properties了,刚刚直接把这个屏蔽就可以了 log4j.rootLogger=DEBUG, stdout

屏蔽??? log4j.rootLogger不应该删的啊

现在是这么配置的,修改哪可以屏蔽DEBUG、INFO 信息呢?

log4j.rootLogger=DEBUG, stdout

log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%-d{MM-dd HH\:mm\:ss.SSS}  %-5p - [%c{1}.%t] %m%n
log4j.rootLogger=DEBUG, stdout
log4j.logger.org.nutz=WARN

log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%-d{MM-dd HH\:mm\:ss.SSS}  %-5p - [%c{1}.%t] %m%n
添加回复
请先登陆
回到顶部