mirror of
https://gitee.com/incloudcode/yexuejc-springboot.git
synced 2025-08-06 10:39:30 +08:00
1.1.3 日志优化
This commit is contained in:
parent
d01690dffb
commit
5bf66c25ca
28
UPDATE.md
28
UPDATE.md
@ -1,6 +1,34 @@
|
|||||||
yexuejc-springboot 更新内容
|
yexuejc-springboot 更新内容
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
|
#### version :1.1.3
|
||||||
|
**time:2018-10-27 16:40:36** <br/>
|
||||||
|
**branch:** master <br/>
|
||||||
|
**关联工程:** <br/>
|
||||||
|
```
|
||||||
|
springboot-base:1.1.9
|
||||||
|
spring-boot-starter-parent:1.5.16.RELEASE
|
||||||
|
```
|
||||||
|
**update:** <br/>
|
||||||
|
1. 日志优化,按天切割日志<br>
|
||||||
|
内置 <br>
|
||||||
|
LogUtil.accessLogger.info(xxxx);请求访问控制,级别info[LogInterceptor->line39](com.yexuejc.springboot.base.interceptor.LogInterceptor)<br>
|
||||||
|
LogUtil.bizLogger.info(xxxx); 业务日志,级别trace<br>
|
||||||
|
LogUtil.exceptionLogger.error(xxxx);异常日志,级别error<br>
|
||||||
|
```$xslt
|
||||||
|
日志配置置于application.properties
|
||||||
|
详情参考 logback-spring.xml
|
||||||
|
|
||||||
|
#日志contextName
|
||||||
|
spring.application.name=@pom.artifactId@
|
||||||
|
#日志级别
|
||||||
|
logging.level.root=info
|
||||||
|
#日志输出目录
|
||||||
|
logging.path=/logs/yexuejc-springboot-parent
|
||||||
|
|
||||||
|
```
|
||||||
|
#
|
||||||
|
|
||||||
#### version :1.1.2
|
#### version :1.1.2
|
||||||
**time:2018-9-28 15:23:32** <br/>
|
**time:2018-9-28 15:23:32** <br/>
|
||||||
**branch:** master <br/>
|
**branch:** master <br/>
|
||||||
|
2
pom.xml
2
pom.xml
@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.yexuejc.springboot</groupId>
|
<groupId>com.yexuejc.springboot</groupId>
|
||||||
<artifactId>yexuejc-springboot-parent</artifactId>
|
<artifactId>yexuejc-springboot-parent</artifactId>
|
||||||
<version>1.1.2</version>
|
<version>1.1.3</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<name>${project.artifactId}</name>
|
<name>${project.artifactId}</name>
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>com.yexuejc.springboot</groupId>
|
<groupId>com.yexuejc.springboot</groupId>
|
||||||
<artifactId>yexuejc-springboot-parent</artifactId>
|
<artifactId>yexuejc-springboot-parent</artifactId>
|
||||||
<version>1.1.2</version>
|
<version>1.1.3</version>
|
||||||
<!-- 本地打包:使用相对关联路径 -->
|
<!-- 本地打包:使用相对关联路径 -->
|
||||||
<!--<relativePath>../../yexuejc</relativePath>-->
|
<!--<relativePath>../../yexuejc</relativePath>-->
|
||||||
</parent>
|
</parent>
|
||||||
|
@ -35,4 +35,5 @@ public class LogUtil {
|
|||||||
}
|
}
|
||||||
return msg.replaceAll(";", "_");
|
return msg.replaceAll(";", "_");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user