[logback-dev] [JIRA] Created: (LBCORE-165) Log file in archive created by RollingFileAppender does not have an extension
Stijn Van Bael (JIRA)
noreply-jira at qos.ch
Wed Aug 11 16:16:16 CEST 2010
Log file in archive created by RollingFileAppender does not have an extension
-----------------------------------------------------------------------------
Key: LBCORE-165
URL: http://jira.qos.ch/browse/LBCORE-165
Project: logback-core
Issue Type: Bug
Components: Appender, Rolling
Affects Versions: 0.9.24
Environment: Windows XP
Reporter: Stijn Van Bael
Assignee: Logback dev list
Priority: Minor
When creating a rolling file appender (see configuration below), the log file within the zipped archive has no extension. This is quite annoying on a Windows system since Windows has no clue how to open a file without extension. You have to rename the file and add the correct extension or choose the program to open over and over again.
Suggested fix: make the file in the archive inherit the extension from the original log file. So for an archive named "log-2010-08-11.zip", the log file within the archive would become "log-2010-08-11.txt", since the original log file was "log.txt".
<appender name="ROLLING" class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>log.txt</file>
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<fileNamePattern>log-%d{yyyy-MM-dd}.zip</fileNamePattern>
<maxHistory>60</maxHistory>
</rollingPolicy>
<encoder>
<pattern>%-4relative [%thread] %-5level %logger{35} - %msg%n</pattern>
</encoder>
</appender>
--
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
More information about the logback-dev
mailing list