You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "Remko Popma (Jira)" <ji...@apache.org> on 2020/06/15 07:46:00 UTC

[jira] [Created] (LOG4J2-2869) Default status logger destination should be STDERR, not STDOUT

Remko Popma created LOG4J2-2869:
-----------------------------------

             Summary: Default status logger destination should be STDERR, not STDOUT
                 Key: LOG4J2-2869
                 URL: https://issues.apache.org/jira/browse/LOG4J2-2869
             Project: Log4j 2
          Issue Type: Bug
          Components: Configuration
    Affects Versions: 2.13.3
            Reporter: Remko Popma


Currently, the default status logging destination for internal Log4j logging is the standard output stream. This is problematic for command line tools whose output is processed by other processes. The default destination for Log4j internal logging should be STDERR.

Note that initially (before the configuration is processed) the status logger actually does output to STDERR, but once the configuration is processed, the {{StatusLogger}} starts to delegate to the {{StatusListeners}}, and the {{StatusConsoleListener}} that is installed by the  {{StatusConfiguration}} has their {{DEFAULT_STREAM}} set to {{System.out}}. I believe this is an oversight and the intention has always been for internal status logging to go to {{System.err}}.





--
This message was sent by Atlassian Jira
(v8.3.4#803005)