[jboss-jira] [JBoss JIRA] (LOGMGR-255) PeriodicRotatingFileHandler doesn't rotate log content when using Compression
Alain Baxter (Jira)
issues at jboss.org
Tue Jun 18 17:13:00 EDT 2019
Alain Baxter created LOGMGR-255:
-----------------------------------
Summary: PeriodicRotatingFileHandler doesn't rotate log content when using Compression
Key: LOGMGR-255
URL: https://issues.jboss.org/browse/LOGMGR-255
Project: JBoss Log Manager
Issue Type: Bug
Reporter: Alain Baxter
When configuring a PeriodicRotatingFileHandler where the suffix ends with .zip or .gz, as such:
{noformat}
<periodic-rotating-file-handler name="FILE" autoflush="true">
<formatter>
<named-formatter name="PATTERN"/>
</formatter>
<file relative-to="jboss.server.log.dir" path="server.log"/>
<suffix value=".yyyy-MM-dd.gz"/>
<append value="true"/>
</periodic-rotating-file-handler>
{noformat}
This is supposed to compressed the rotated logs to save space. See https://issues.jboss.org/browse/LOGMGR-30
What I'm seeing is that the rotation log file is successfully created and compressed at the periodic interval, however the log file content is not removed.
This means that the log file itself continues to grow instead of rotating log content, and each rotation log contains the content from all the previous, so their size gets larger and larger:
{noformat}
-rw-r--r--. 1 jboss jboss 1779799 Jun 18 21:03 server.log
-rw-r--r--. 1 jboss jboss 21831 Jun 18 19:00 server.log.2019-06-18-18.gz
-rw-r--r--. 1 jboss jboss 55168 Jun 18 20:00 server.log.2019-06-18-19.gz
-rw-r--r--. 1 jboss jboss 88021 Jun 18 21:00 server.log.2019-06-18-20.gz
{noformat}
*NOTE:* This issue would exist for SizeRotatingFileHandler and PeriodicSizeRotatingFileHandler
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
More information about the jboss-jira
mailing list