Package

org.scalatra

slf4j

Permalink

package slf4j

Visibility
  1. Public
  2. All

Type Members

  1. class LevelColorizer extends ClassicConverter

    Permalink

    Adds ANSI colorization of the log level for use in the console.

    Adds ANSI colorization of the log level for use in the console.

    An example of a logback.xml file:

    <configuration>
       <conversionRule conversionWord="levelcolor"
                     converterClass="org.scalatra.slf4j.LevelColorizer" />
    
    
       <contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
    
       <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
         <!-- encoders are assigned the type
              ch.qos.logback.classic.encoder.PatternLayoutEncoder by default -->
         <encoder>
           <pattern>[%4levelcolor] [%d{ISO8601}] [%X{thread}] [%logger{4}]: %m%n</pattern>
         </encoder>
       </appender>
    
       <root level="INFO">
         <appender-ref ref="STDOUT"/>
       </root>
    </configuration>
  2. trait ScalatraSlf4jRequestLogging extends ScalatraBase with Handler

    Permalink

Value Members

  1. object LevelColorizer

    Permalink
  2. object ScalatraSlf4jRequestLogging

    Permalink

Ungrouped