<?xml version="1.0" encoding="UTF-8" ?>
<configuration>
    <springProperty name="spring.application.name" source="spring.application.name"/>
    <property name="LOG_LEVEL_PATTERN"
              value="%5p [${spring.application.name:-},%X{X-B3-TraceId:-},%X{X-B3-SpanId:-},%X{X-Span-Export:-}]"/>
    <property name="FILE_LOG_PATTERN"
              value="${FILE_LOG_PATTERN:-%d{yyyy-MM-dd HH:mm:ss.SSS} ${LOG_LEVEL_PATTERN:-%5p} --- [%thread] [%file:%line] %logger - %msg%n}"/>

    <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <file>/vpants/shaun/asset-distribution-9051/logs/asset-distribution.log</file>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>
                /vpants/shaun/asset-distribution-9051/logs/asset-distribution.log.%d{yyyy-MM-dd}
            </fileNamePattern>
            <maxHistory>7</maxHistory>
        </rollingPolicy>
        <encoder>
            <pattern>${FILE_LOG_PATTERN}</pattern>
        </encoder>
    </appender>

    <logger name="com.atomikos" level="warn"/>
    <logger name="org.springframework" level="warn"/>
    <logger name="org.mybatis" level="warn"/>
    <logger name="org.apache" level="warn"/>
    <logger name="ch.qos.logback" level="warn"/>
    <logger name="org.apache.kafka.clients" level="error"/>

    <root level="info">
        <appender-ref ref="FILE"/>
    </root>

</configuration>