-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
56 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
<configuration> | ||
<!-- 전체 설정의 시작 --> | ||
|
||
<!-- INFO 이상 모든 로그를 기록할 Appender --> | ||
<appender name="ALL_LOG" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
<file>logs/all/logFile.log</file> | ||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
<fileNamePattern>logs/all/logFile.%d{yyyy-MM-dd}.log</fileNamePattern> | ||
<maxHistory>30</maxHistory> | ||
<totalSizeCap>100MB</totalSizeCap> | ||
</rollingPolicy> | ||
<encoder> | ||
<pattern>%-4relative [%thread] %-5level %logger{35} - %msg%n</pattern> | ||
</encoder> | ||
</appender> | ||
|
||
<!-- WARN 레벨 이상의 로그만 기록할 Appender --> | ||
<appender name="WARN_LOG" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
<file>logs/warn/logFile.log</file> | ||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
<fileNamePattern>logs/warn/logFile.%d{yyyy-MM-dd}.log</fileNamePattern> | ||
<maxHistory>30</maxHistory> | ||
<totalSizeCap>100MB</totalSizeCap> | ||
</rollingPolicy> | ||
<encoder> | ||
<pattern>%-4relative [%thread] %-5level %logger{35} - %msg%n</pattern> | ||
</encoder> | ||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter"> | ||
<level>WARN</level> | ||
</filter> | ||
</appender> | ||
|
||
<!-- ERROR 레벨 이상의 로그만 기록할 Appender --> | ||
<appender name="ERROR_LOG" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
<file>logs/error/logFile.log</file> | ||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
<fileNamePattern>logs/error/logFile.%d{yyyy-MM-dd}.log</fileNamePattern> | ||
<maxHistory>30</maxHistory> | ||
<totalSizeCap>100MB</totalSizeCap> | ||
</rollingPolicy> | ||
<encoder> | ||
<pattern>%-4relative [%thread] %-5level %logger{35} - %msg%n</pattern> | ||
</encoder> | ||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter"> | ||
<level>ERROR</level> | ||
</filter> | ||
</appender> | ||
|
||
<!-- Root Logger 설정 --> | ||
<root level="INFO"> | ||
<appender-ref ref="ALL_LOG"/> | ||
<appender-ref ref="WARN_LOG"/> | ||
<appender-ref ref="ERROR_LOG"/> | ||
</root> | ||
</configuration> |