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

glowroot-central.0.13.6.source-code.logback.xml Maven / Gradle / Ivy

There is a newer version: 0.14.0-beta.3
Show newest version
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration>
<configuration>

  <!-- to edit this file, copy it to the glowroot-central folder (where glowroot-central.jar
    resides), keeping the same file name (logback.xml), and glowroot-central will find it and use it
    instead of the logback.xml configuration file that is inside glowroot-central.jar -->

  <appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
    <encoder>
      <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %-5level %logger{36} - %msg%n</pattern>
    </encoder>
  </appender>
  <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
    <file>${glowroot.log.dir}/glowroot-central.log</file>
    <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
      <fileNamePattern>${glowroot.log.dir}/glowroot-central.%i.log</fileNamePattern>
      <minIndex>1</minIndex>
      <maxIndex>10</maxIndex>
    </rollingPolicy>
    <triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
      <maxFileSize>10MB</maxFileSize>
    </triggeringPolicy>
    <encoder>
      <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %-5level %logger{36} - %msg%n</pattern>
    </encoder>
  </appender>
  <contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator" />
  <!-- AggregateFuture is used by Futures.allAsList() and it logs all the failures after the first
    failure (the first failure is reported via the resulting Future.get()), which typically results
    in lots of spamming of similar errors (e.g. Cassandra timeouts) -->
  <logger name="com.google.common.util.concurrent.AggregateFuture" level="off" />
  <root level="info">
    <!-- use -Dglowroot.log.consoleOff=true to turn off console logging -->
    <if condition="p(&quot;glowroot.log.consoleOff&quot;).equalsIgnoreCase(&quot;true&quot;)">
      <else>
        <appender-ref ref="CONSOLE" />
      </else>
    </if>
    <appender-ref ref="FILE" />
  </root>

  <!-- use -Dglowroot.log.auditOn=true to turn on audit logging -->
  <if condition="p(&quot;glowroot.log.auditOn&quot;).equalsIgnoreCase(&quot;true&quot;)">
    <then>
      <appender name="AUDIT" class="ch.qos.logback.core.rolling.RollingFileAppender">
        <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
          <fileNamePattern>
            ${glowroot.log.dir}/glowroot-central-audit.%d{yyyy-MM-dd}.log
          </fileNamePattern>
          <maxHistory>30</maxHistory>
        </rollingPolicy>
        <encoder>
          <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} - %msg%n</pattern>
        </encoder>
      </appender>
      <logger name="audit" level="info" additivity="false">
        <appender-ref ref="AUDIT" />
      </logger>
    </then>
    <else>
      <logger name="audit" level="off" />
    </else>
  </if>
</configuration>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy