springboot logger 配置

logger 配置

1
2
3
4
5
6
7
8
9
10
logging:
config: classpath:logback-spring.xml
level:
com:
netflix: info
wuxinvip: info
wuxinvip.mapper: DEBUG
org:
springframework: info
root: info
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

<?xml version="1.0" encoding="UTF-8"?>

<!-- For assistance related to logback-translator or configuration -->
<!-- files in general, please contact the logback user mailing list -->
<!-- at http://www.qos.ch/mailman/listinfo/logback-user -->
<!-- -->
<!-- For professional support please see -->
<!-- http://www.qos.ch/shop/products/professionalSupport
http://logback.qos.ch/translator/
-->
<configuration>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d %p [%c] - &lt;%m&gt;%n</pattern>
</encoder>
</appender>
<root>
<appender-ref ref="console"/>
</root>

</configuration>