Uploaded image for project: 'logback'
  1. logback
  2. LOGBACK-1482

RollingFileAppender creates .tmp file while creating GZ file at midnight

    Details

    • Type: Bug
    • Status: Open
    • Priority: Critical
    • Resolution: Unresolved
    • Affects Version/s: 1.3.0-alpha4
    • Fix Version/s: None
    • Component/s: logback-classic
    • Environment:

      This is happening in production environment.

      Description

      After migrating our servers to openjdk11 we started observing this issue.

      We are using below configuration currently. We started using the latest versions of logback and slf4j.

      <version.java>11</version.java>

      <version.logback>1.3.0-alpha4</version.logback>

      <version.slf4j>1.8.0-beta4</version.slf4j>

      <dependency>

      <groupId>ch.qos.logback</groupId>

      <artifactId>logback-classic</artifactId>

      <version>${version.logback}</version>

      <scope>runtime</scope>

      </dependency>

      <dependency>

      <groupId>org.slf4j</groupId>

      <artifactId>log4j-over-slf4j</artifactId>

      <version>${version.slf4j}</version>

      <scope>runtime</scope>

      </dependency>

       

      We are using 

      SizeAndTimeBasedRollingPolicy as rolling policy and rollover is set at midnight. 

       

      Basically the roll over happens properly creating .gz file but at the same time it creates .tmp file for application log.

       
      rw-r---- 1 user user  7805929 Aug 11 00:00 application-metrics-2019-08-10.1.log.gz
      rw-r---- 1 user user     8216 Aug 11 00:34 application-dead-letters.log
      rw-r---- 1 user user 14956341 Aug 11 14:33 application-metrics-2019-08-11.0.log.gz
      rw-r---- 1 user user   416634 Aug 12 00:00 application-2019-08-11.0.log.gz
      rw-r---- 1 user user    13780 Aug 12 00:00 application-2019-08-11.0.log2815836846996630.tmp
       
      I have referred all open and closed tickets on this topic but nothing helped to resolve our issue. So please. I have attached logbook.xml file we are using.

        Attachments

          Activity

            People

            • Assignee:
              logback-dev Logback dev list
              Reporter:
              Abhijit Kangale Abhijit Kangale
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: