You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "NamHyoekJoon (Jira)" <ji...@apache.org> on 2023/03/11 18:10:00 UTC
[jira] [Created] (LOG4J2-3653) RollingFile TimeZone still doesn't work
NamHyoekJoon created LOG4J2-3653:
------------------------------------
Summary: RollingFile TimeZone still doesn't work
Key: LOG4J2-3653
URL: https://issues.apache.org/jira/browse/LOG4J2-3653
Project: Log4j 2
Issue Type: Bug
Components: Appenders
Affects Versions: 2.20.0
Environment: Java 17
Spring Boot 2.7.9
Log4j2 2.20
Reporter: NamHyoekJoon
It has been reported that the RollingFile TimeZone issue has been fixed in version 2.20.
But it still follows the server time and the TimeZone I specified is ignored.
{code:java}
<RollingFile name="DefaultAppender" fileName="${sys:LOG_PATH}/${sys:DEFAULT_LOG_NAME}" filePattern="./log/backup/default/app2-%d{yyyy-MM-dd}{GMT+9}.log.gz">
<PatternLayout pattern="${sys:FILE_LOG_PATTERN}"/>
<Policies>
<CronTriggeringPolicy schedule="0 0 17 * * ? *" />
<SizeBasedTriggeringPolicy size="10 MB" />
</Policies>
</RollingFile>
{code}
Action I wanted: Action at 08:00:00 UTC.
Actual operation: Operates at 17:00:00 UTC.
The time I specify should be the same as my locale's time reflected by the TimeZone.
But still my TimeZone in terms of UTC is meaningless.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)