Logback: Difference between revisions
Jump to navigation
Jump to search
(Created page with "=External= * https://logback.qos.ch =Internal= * Java") |
|||
Line 6: | Line 6: | ||
* [[Java#Logging|Java]] | * [[Java#Logging|Java]] | ||
=Example= | |||
<syntaxhighlight lang='xml'> | |||
<configuration> | |||
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> | |||
<encoder> | |||
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n </pattern> | |||
</encoder> | |||
</appender> | |||
<logger name="root" level="INFO"/> <root level="INFO"> | |||
<appender-ref ref="STDOUT" /> </root> | |||
</configuration> | |||
</syntaxhighlight> |
Revision as of 19:36, 22 September 2018
External
Internal
Example
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n </pattern>
</encoder>
</appender>
<logger name="root" level="INFO"/> <root level="INFO">
<appender-ref ref="STDOUT" /> </root>
</configuration>