Skip to content

Commit

Permalink
Migrate SizeAndTimeBasedFNATP to SizeAndTimeBasedRollingPolicy
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrp committed Nov 25, 2024
1 parent deaec57 commit 6d39ce8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 16 deletions.
12 changes: 4 additions & 8 deletions engine/lite/runtime-app/src/universal/conf/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,10 @@
<file>${LOGS_DIR:-./logs}/nussknacker-runtime.log</file>
<append>true</append>

<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOGS_DIR:-./logs}/nussknacker-runtime.log.%d{yyyy-MM-dd}.%i.gz</fileNamePattern>
<maxHistory>30</maxHistory>
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
<maxFileSize>100MB</maxFileSize>
</timeBasedFileNamingAndTriggeringPolicy>
<maxFileSize>100MB</maxFileSize>
</rollingPolicy>
<encoder>
<Pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</Pattern>
Expand All @@ -33,12 +31,10 @@
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>WARN</level>
</filter>
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOGS_DIR:-./logs}/nussknacker-runtime-error.log.%d{yyyy-MM-dd}.%i.gz</fileNamePattern>
<maxHistory>30</maxHistory>
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
<maxFileSize>100MB</maxFileSize>
</timeBasedFileNamingAndTriggeringPolicy>
<maxFileSize>100MB</maxFileSize>
</rollingPolicy>
<encoder>
<Pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</Pattern>
Expand Down
12 changes: 4 additions & 8 deletions nussknacker-dist/src/universal/conf/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,10 @@
<file>${LOGS_DIR:-./logs}/nussknacker-designer.log</file>
<append>true</append>

<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOGS_DIR:-./logs}/nussknacker-designer.log.%d{yyyy-MM-dd}.%i.gz</fileNamePattern>
<maxHistory>30</maxHistory>
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
<maxFileSize>100MB</maxFileSize>
</timeBasedFileNamingAndTriggeringPolicy>
<maxFileSize>100MB</maxFileSize>
</rollingPolicy>
<encoder>
<Pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</Pattern>
Expand All @@ -33,12 +31,10 @@
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>WARN</level>
</filter>
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOGS_DIR:-./logs}/nussknacker-designer-error.log.%d{yyyy-MM-dd}.%i.gz</fileNamePattern>
<maxHistory>30</maxHistory>
<timeBasedFileNamingAndTriggeringPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
<maxFileSize>100MB</maxFileSize>
</timeBasedFileNamingAndTriggeringPolicy>
<maxFileSize>100MB</maxFileSize>
</rollingPolicy>
<encoder>
<Pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</Pattern>
Expand Down

0 comments on commit 6d39ce8

Please sign in to comment.