You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by "Bart S. (JIRA)" <ji...@apache.org> on 2015/08/12 20:21:45 UTC
[jira] [Created] (LOG4J2-1091) StatusLogger no display errors from
Appender misconfiguration
Bart S. created LOG4J2-1091:
-------------------------------
Summary: StatusLogger no display errors from Appender misconfiguration
Key: LOG4J2-1091
URL: https://issues.apache.org/jira/browse/LOG4J2-1091
Project: Log4j 2
Issue Type: Bug
Components: Appenders
Affects Versions: 2.4
Environment: Simple standalone runtime initializing the logging system in a default way. Windows 7 x64. Newest Java 8 JDK. Latest clone off of git.
Reporter: Bart S.
Priority: Minor
When a {{FileAppender}} is created using the {{createAppender}} method with parameters that conflict with each other are incorrect -- null values for the fileName, for instance, the code will execute {{LOGGER.warn()}} or {{LOGGER.error()}}. Typically this should send output through the statuslogger as defined in AbstractLifeCycle. In there a static LOGGER is simply assigned by:
{{protected static final org.apache.logging.log4j.Logger LOGGER = StatusLogger.getLogger();}}
>From injecting a System.out.println it is clear that the code must be getting executed. It just doesn't produce anything, even though the returned value is null, referencing the fact that the code decided that having a filename would be important. There are other ways to trigger an error or warning, for instance by supplying both "locking" and "bufferedIo" as _true_. In all cases no output message is generated. I have no clue why.
I have written on the user list about it, but the emails are not getting through yet. Attached file reproduces the error. Happens both with core version 2.3, and the latest 'trunk' of 2.4.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org