生产环境的 log 输出级别该为 INFO。
[jibu.git] / jibu-core / src / main / resources / logback.xml
blob67effdd4b15983b6cd9c11e8bfaa507af3cf3201
1 <configuration>
2   <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
3     <file>jibu.log</file>
4     <!-- encoders are assigned by default the type
5          ch.qos.logback.classic.encoder.PatternLayoutEncoder -->
6     <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
7       <!-- daily rollover -->
8       <fileNamePattern>jibu.%d{yyyy-MM-dd}.log</fileNamePattern>
10       <!-- keep 30 days' worth of history -->
11       <maxHistory>30</maxHistory>
12     </rollingPolicy>
14     <encoder>
15       <pattern>%d{HH:mm:ss.SSS} %-5level [%thread] %logger{36} [%line] - %msg%n</pattern>
16     </encoder>
17   </appender>
19   <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
20     <encoder>
21       <pattern>%d{HH:mm:ss.SSS} %-5level [%thread] %logger{16} [%line] - %msg%n</pattern>
22     </encoder>
23   </appender>
25   <logger name="org.gaixie.jibu" level="INFO"/>
27   <root level="WARN">
28     <appender-ref ref="FILE" />
29   </root>
30 </configuration>