Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev 서버 로그 안찍히는 문제 해결 #295

Merged
merged 2 commits into from
Aug 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions backend/src/main/resources/logback-spring.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" scanPeriod="5 seconds">

<property name="LOG_FILE_PATH" value="./spring-log"/>
<timestamp key="DATE_FORMAT" datePattern="yyyy-MM-dd"/>

<springProfile name="local">
Expand Down
2 changes: 1 addition & 1 deletion backend/src/main/resources/logger/file/error-appender.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
</encoder>

<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_FILE_PATH}/${DATE_FORMAT}/error/error%i.log</fileNamePattern>
<fileNamePattern>${LOG_FILE_PATH}/%d{yyyy-MM-dd}/error/error%i.log</fileNamePattern>
<maxFileSize>50MB</maxFileSize>
<maxHistory>30</maxHistory>
</rollingPolicy>
Expand Down
2 changes: 1 addition & 1 deletion backend/src/main/resources/logger/file/info-appender.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
</encoder>

<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_FILE_PATH}/${DATE_FORMAT}/info/info%i.log</fileNamePattern>
<fileNamePattern>${LOG_FILE_PATH}/%d{yyyy-MM-dd}/info/info%i.log</fileNamePattern>
<maxFileSize>50MB</maxFileSize>
<maxHistory>30</maxHistory>
</rollingPolicy>
Expand Down
2 changes: 1 addition & 1 deletion backend/src/main/resources/logger/file/warn-appender.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
</encoder>

<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_FILE_PATH}/${DATE_FORMAT}/warn/warn%i.log</fileNamePattern>
<fileNamePattern>${LOG_FILE_PATH}/%d{yyyy-MM-dd}/warn/warn%i.log</fileNamePattern>
<maxFileSize>50MB</maxFileSize>
<maxHistory>30</maxHistory>
</rollingPolicy>
Expand Down
2 changes: 0 additions & 2 deletions backend/src/main/resources/logger/logback-spring-dev.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
<include resource="logger/file/warn-appender.xml"/>
<include resource="logger/file/error-appender.xml"/>

<property name="LOG_FILE_PATH" value="./spring-log"/>

<root level="INFO">
<appender-ref ref="info-appender"/>
<appender-ref ref="warn-appender"/>
Expand Down
2 changes: 0 additions & 2 deletions backend/src/main/resources/logger/logback-spring-prod.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
<configuration scan="true" scanPeriod="5 seconds">
<include resource="logger/file/error-appender.xml"/>

<property name="LOG_FILE_PATH" value="./spring-log"/>

<root level="ERROR">
<appender-ref ref="error-appender"/>
</root>
Expand Down
Loading