Log4j: Add thread id in appender

Sometimes it's usefull to see the thread id of the logged output.

Bug: Issue 3361
Change-Id: I3e9d0e33b4aece270057217725b05f543e71e551
This commit is contained in:
David Ostrovsky 2015-10-07 08:55:10 +02:00 committed by Edwin Kempin
parent 85cbe36cc1
commit 1a8c7aa07a
2 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@ public class ErrorLogFile {
if (text) {
root.addAppender(SystemLog.createAppender(logdir, LOG_NAME,
new PatternLayout("[%d] %-5p %c %x: %m%n")));
new PatternLayout("[%d] [%t] %-5p %c %x: %m%n")));
}
if (json) {

View File

@ -16,7 +16,7 @@ log4j.rootCategory=INFO, stderr
log4j.appender.stderr=org.apache.log4j.ConsoleAppender
log4j.appender.stderr.target=System.err
log4j.appender.stderr.layout=org.apache.log4j.PatternLayout
log4j.appender.stderr.layout.ConversionPattern=[%d] %-5p %c %x: %m%n
log4j.appender.stderr.layout.ConversionPattern=[%d] [%t] %-5p %c %x: %m%n
# Silence non-critical messages from MINA SSHD.
#