All Downloads are FREE. Search and download functionalities are using the official Maven repository.

x-samplest-kotlin.1.1.0.source-code.logback.xml Maven / Gradle / Ivy

There is a newer version: 1.2.0-rc2
Show newest version
<configuration>
    <contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator">
        <resetJUL>true</resetJUL>
    </contextListener>
    <property name="LOGS_FOLDER" value="${logs.base:-logs}" />

    <appender name="errorFile" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <File>${LOGS_FOLDER}/errors.log</File>
        <filter class="ch.qos.logback.classic.filter.ThresholdFilter">
            <level>ERROR</level>
        </filter>
        <encoder>
            <pattern>%d [%-16thread] [%-10X{principal}] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
            <fileNamePattern>${LOGS_FOLDER}/errors.%d.log</fileNamePattern>
            <maxHistory>30</maxHistory>
        </rollingPolicy>
    </appender>

    <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
        <encoder>
            <pattern>%d [%-16thread] [%-10X{principal}] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
    </appender>
    <appender name="appLog" class="ch.qos.logback.core.FileAppender">
        <File>${LOGS_FOLDER}/app.log</File>
        <encoder>
            <pattern>%d [%-16thread] [%-10X{principal}] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
    </appender>

    <!-- clean up container logs -->
    <logger name="org.eclipse.jetty.server.AbstractConnector" level="WARN" />
    <logger name="org.eclipse.jetty.server.handler.ContextHandler" level="WARN" />
    <logger name="org.eclipse.jetty.webapp.StandardDescriptorProcessor" level="WARN" />

    <logger name="org.hibernate.validator.internal.engine.ConfigurationImpl" level="WARN" />
    <logger name="org.reflections.Reflections" level="WARN" />

    <logger name="restx.factory.Factory" level="WARN" />

    <!-- app logs -->
    <logger name="samplest" level="DEBUG" />

    <root level="INFO">
        <appender-ref ref="STDOUT" />
        <appender-ref ref="appLog" />
        <appender-ref ref="errorFile" />
    </root>
</configuration>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy