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

control plugin log fix #12669

Merged
merged 2 commits into from
Sep 27, 2024
Merged
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
56 changes: 27 additions & 29 deletions distribution/conf/nacos-logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -479,48 +479,47 @@


<!--TPS control -->
<appender name="tps-control"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/tps-control.log</file>
<appender name="plugin-control-connection"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/plugin-control-connection.log</file>
<append>true</append>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_HOME}/tps-control.log.%d{yyyy-MM-dd}.%i</fileNamePattern>
<fileNamePattern>${LOG_HOME}/plugin-control-connection.log.%d{yyyy-MM-dd}.%i</fileNamePattern>
<maxFileSize>2GB</maxFileSize>
<maxHistory>7</maxHistory>
<totalSizeCap>7GB</totalSizeCap>
<totalSizeCap>2GB</totalSizeCap>
<cleanHistoryOnStart>true</cleanHistoryOnStart>
</rollingPolicy>
<encoder>
<Pattern>%date %level %msg%n%n</Pattern>
<charset>UTF-8</charset>
</encoder>
</appender>

<appender name="tps-control-digest"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/tps-control-digest.log</file>
<appender name="plugin-control-tps"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/plugin-control-tps.log</file>
<append>true</append>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_HOME}/tps-control-digest.log.%d{yyyy-MM-dd}.%i</fileNamePattern>
<fileNamePattern>${LOG_HOME}/plugin-control-tps.log.%d{yyyy-MM-dd}.%i</fileNamePattern>
<maxFileSize>2GB</maxFileSize>
<maxHistory>7</maxHistory>
<totalSizeCap>7GB</totalSizeCap>
<totalSizeCap>2GB</totalSizeCap>
<cleanHistoryOnStart>true</cleanHistoryOnStart>
</rollingPolicy>
<encoder>
<Pattern>%date %level %msg%n%n</Pattern>
<charset>UTF-8</charset>
</encoder>
</appender>
<appender name="tps-control-detail"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/tps-control-detail.log</file>

<appender name="plugin-control"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>${LOG_HOME}/plugin-control.log</file>
<append>true</append>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${LOG_HOME}/tps-control-detail.log.%d{yyyy-MM-dd}.%i</fileNamePattern>
<fileNamePattern>${LOG_HOME}/plugin-control.%d{yyyy-MM-dd}.%i</fileNamePattern>
<maxFileSize>2GB</maxFileSize>
<maxHistory>7</maxHistory>
<maxHistory>14</maxHistory>
<totalSizeCap>7GB</totalSizeCap>
<cleanHistoryOnStart>true</cleanHistoryOnStart>
</rollingPolicy>
Expand Down Expand Up @@ -622,21 +621,20 @@
<level value="DEBUG"/>
<appender-ref ref="remote-digest"/>
</logger>

<!-- TPS Control-->
<logger name="com.alibaba.nacos.core.remote.control.digest" additivity="false">
<level value="DEBUG"/>
<appender-ref ref="tps-control-digest"/>
<logger name="com.alibaba.nacos.plugin.control" additivity="false">
<level value="INFO"/>
<appender-ref ref="plugin-control"/>
</logger>

<logger name="com.alibaba.nacos.core.remote.control.detail" additivity="false">
<level value="DEBUG"/>
<appender-ref ref="tps-control-detail"/>
<logger name="com.alibaba.nacos.plugin.control.tps" additivity="false">
<level value="INFO"/>
<appender-ref ref="plugin-control-tps"/>
</logger>
<logger name="com.alibaba.nacos.core.remote.control" additivity="false">
<level value="DEBUG"/>
<appender-ref ref="tps-control"/>

<logger name="com.alibaba.nacos.plugin.control.connection" additivity="false">
<level value="INFO"/>
<appender-ref ref="plugin-control-connection"/>
</logger>

<logger name="com.alibaba.nacos.naming.main" additivity="false">
Expand Down
Loading