[JIRA] Created: (LBCORE-199) RollingFileAppender with zip & %i doesn't rename active log file before being zipped

RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------ Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Logback dev list http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) .... -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-199?page=com.atlassian.jira.plugin.system.i... ] Benoit Xhenseval commented on LBCORE-199: ----------------------------------------- I would suggest that if using the same count inside the ZIP file is too consuming (eg doesn't the file rename happen too often?) then it might be sufficient to add a timestamp on each file being zipped in order to ensure that they are UNIQUE accross the zip files. Thanks!
RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------
Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Logback dev list
http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) ....
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-199?page=com.atlassian.jira.plugin.system.i... ] Ceki Gulcu updated LBCORE-199: ------------------------------ Priority: Critical (was: Major)
RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------
Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Logback dev list Priority: Critical
http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) ....
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-199?page=com.atlassian.jira.plugin.system.i... ] Ceki Gulcu reassigned LBCORE-199: --------------------------------- Assignee: Ceki Gulcu (was: Logback dev list)
RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------
Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Ceki Gulcu Priority: Critical
http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) ....
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-199?page=com.atlassian.jira.plugin.system.i... ] Ceki Gulcu resolved LBCORE-199. ------------------------------- Fix Version/s: 0.9.29 Resolution: Fixed Fixed in http://github.com/ceki/logback/commit/79989e013e314 as suggested by Benoit Xhenseval by adding a timestamp to the entry in the zip file.
RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------
Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Ceki Gulcu Priority: Critical Fix For: 0.9.29
http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) ....
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira

[ http://jira.qos.ch/browse/LBCORE-199?page=com.atlassian.jira.plugin.system.i... ] Ceki Gulcu edited comment on LBCORE-199 at 5/25/11 4:36 PM: ------------------------------------------------------------ Hello all, This is now fixed in [1] as suggested by Benoit Xhenseval by adding a timestamp to the entry in the zip file. [1] http://github.com/ceki/logback/commit/79989e013e314 was (Author: noreply.ceki@qos.ch): Fixed in http://github.com/ceki/logback/commit/79989e013e314 as suggested by Benoit Xhenseval by adding a timestamp to the entry in the zip file.
RollingFileAppender with zip & %i doesn't rename active log file before being zipped ------------------------------------------------------------------------------------
Key: LBCORE-199 URL: http://jira.qos.ch/browse/LBCORE-199 Project: logback-core Issue Type: Bug Components: Rolling Affects Versions: 0.9.28 Reporter: Deepak Vadgama Assignee: Ceki Gulcu Priority: Critical Fix For: 0.9.29
http://old.nabble.com/RollingFileAppender-with-compress----i-td31037552.html When compression is used for FixedWindowRollingPolicy, with %i in the file name pattern, the log files are not renamed with %i before compression. Resulting zip-files are created with appropriate rolled over names (%i). But all the log files inside those zip have a same name. Configuration (non relevant elements removed before posting) <appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>logs/gateway.log</File> <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy"> <maxIndex>20</maxIndex> <FileNamePattern>logs/gateway.log.%i.zip</FileNamePattern> </rollingPolicy> </appender> Results gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.1) gateway.log.3.zip (with log file gateway.log.1) ... Should have been gateway.log.1.zip (with log file gateway.log.1) gateway.log.2.zip (with log file gateway.log.2) gateway.log.3.zip (with log file gateway.log.3) ....
-- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
participants (3)
-
Benoit Xhenseval (JIRA)
-
Ceki Gulcu (JIRA)
-
Deepak Vadgama (JIRA)