Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-1075

Support bzip2 compression format for rollover

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.3
    • 2.4
    • Appenders
    • None

    Description

      RollingFileAppender and RollingRandomAccessFileAppender currently support two compression formats: gzip and zip. Java has built-in support for these formats so these are guaranteed to work without external dependencies.

      However, there are formats that give much better compression, for example bzip2 results in 40% smaller files.

      At work, we have a requirement to store large log files in smaller format for long term storage. I would like to be able to do this at rollover. Currently we gzip at rollover and have a separate script unzip and bzip2 these files. It would be convenient to be able to use bzip2 directly from log4j at rollover.

      We can leverage the work done here: https://commons.apache.org/proper/commons-compress/

      Attachments

        Issue Links

          Activity

            People

              rpopma Remko Popma
              rpopma Remko Popma
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: