<!--To prevent data loss in memory when the process exits, add this configuration.-->
<shutdownHook class="ch.qos.logback.core.hook.DelayingShutdownHook"/>
<!-- Configure the appender whose log output destination is TLS -->
<appender name="TLSLogbackAppender" class="com.volcengine.service.tls.logback.LogbackAppender">
<!-- Required configuration: TLS log service basic configuration -->
<accessKeyId></accessKeyId>
<accessKeySecret></accessKeySecret>
<!-- Required configuration: TLS project/topic configuration -->
<!-- Optional configuration: log data source configuration -->
<!-- Optional configuration: TLS Java Producer custom configuration -->
<totalSizeInBytes>104857600</totalSizeInBytes>
<maxThreadCount>50</maxThreadCount>
<maxBlockMs>60000</maxBlockMs>
<maxBatchSizeBytes>524288</maxBatchSizeBytes>
<maxBatchCount>4096</maxBatchCount>
<lingerMs>2000</lingerMs>
<retryCount>2</retryCount>
<maxReservedAttempts>3</maxReservedAttempts>
<!-- Optional configuration: custom log format via encoder pattern -->
<pattern>%d %-5level [%thread] %logger{0}: %msg</pattern>
<!-- Optional configuration: set time format -->
<timeFormat>yyyy-MM-dd'T'HH:mmZ</timeFormat>
<!-- Optional configuration: set time zone -->
<timeZone>Asia/Shanghai</timeZone>
<!-- Optional configuration: configure LevelFilter -->
<filter class="ch.qos.logback.classic.filter.LevelFilter">
<onMatch>ACCEPT</onMatch>
<onMismatch>DENY</onMismatch>
<!-- Optional configuration: configure mdcFields -->
<mdcFields>THREAD_ID,MDC_KEY</mdcFields>
<!-- Configure log output destination as appender from Stdout -->
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger - %msg %X{THREAD_ID} %n</pattern>
<!-- Can be used to obtain status from StatusManager -->
<statusListener class="ch.qos.logback.core.status.OnConsoleStatusListener"/>
<!-- Solve problems of repeatedly transmission under debug mode -->
<logger name="org.apache.http.impl.conn.Wire" level="WARN" />
<appender-ref ref="TLSLogbackAppender"/>
<appender-ref ref="STDOUT"/>