sofa-thread.log.log4j2.log-conf.xml Maven / Gradle / Ivy
The newest version!
<?xml version="1.0" encoding="UTF-8"?> <configuration status="OFF"> <Properties> <Property name="THREAD_LOG_LEVEL">${sys:logging.level.sofa-thread}</Property> <Property name="THREAD_LOG_PATH">${sys:logging.path}</Property> <Property name="THREAD_FILE_ENCODING">${sys:file.encoding}</Property> </Properties> <appenders> <RollingFile name="WARN-APPENDER" fileName="${THREAD_LOG_PATH}/sofa-thread/aberrant-digest.log" append="true" filePattern="${THREAD_LOG_PATH}/sofa-thread/aberrant-error.log.%d{yyyy-MM-dd}"> <ThresholdFilter level="warn" onMatch="ACCEPT" onMismatch="DENY"/> <PatternLayout charset="${THREAD_FILE_ENCODING}"> <pattern>%d %-5p %-5t - %m%n</pattern> </PatternLayout> <Policies> <TimeBasedTriggeringPolicy interval="1" modulate="true"/> </Policies> </RollingFile> <RollingFile name="SOFA-APPENDER" fileName="${THREAD_LOG_PATH}/sofa-thread/thread-digest.log" append="true" filePattern="${THREAD_LOG_PATH}/sofa-thread/thread-digest.log.%d{yyyy-MM-dd}"> <ThresholdFilter level="${THREAD_LOG_LEVEL}" onMatch="ACCEPT" onMismatch="DENY"/> <PatternLayout charset="${THREAD_FILE_ENCODING}"> <pattern>%d %-5p %-5t - %m%n</pattern> </PatternLayout> <Policies> <TimeBasedTriggeringPolicy interval="1" modulate="true"/> </Policies> </RollingFile> </appenders> <loggers> <logger name="com.alipay.sofa.thread" level="${THREAD_LOG_LEVEL}" additivity="false"> <appender-ref ref="SOFA-APPENDER"/> </logger> <logger name="com.alipay.sofa.thread.warn" level="warn" additivity="false"> <appender-ref ref="WARN-APPENDER"/> </logger> <root level="${THREAD_LOG_LEVEL}" additivity="false"> <appender-ref ref="SOFA-APPENDER"/> <appender-ref ref="WARN-APPENDER"/> </root> </loggers> </configuration>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy