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 "Danny Chen (JIRA)" <ji...@apache.org> on 2017/03/30 18:39:41 UTC
[jira] [Created] (LOG4J2-1859) Add rolling date support to
fileName, RollingRandomAccessFile
Danny Chen created LOG4J2-1859:
----------------------------------
Summary: Add rolling date support to fileName, RollingRandomAccessFile
Key: LOG4J2-1859
URL: https://issues.apache.org/jira/browse/LOG4J2-1859
Project: Log4j 2
Issue Type: Improvement
Components: Appenders
Affects Versions: 2.6.2
Environment: All
Reporter: Danny Chen
Priority: Minor
We are currently using Log4j2 version 2.6.2. Within our configuration, we are using RollingRandomAccessFile. For the "filePattern", there is date support and rolling date support. But for "fileName", there is no date rolling support.
Example:
<RollingRandomAccessFile name="RollingRandomAccessFile" fileName="logs/app-${date:yyyy-MM-dd}.log" filePattern="logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
With the above config, once the rolling is done on the next date, the current log file is still the current date. It seems as the current log file name is always fixed. There is no rolling to it.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org