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

FastFileAppender overwrites previous log entries

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0-beta7
    • Fix Version/s: 2.0-beta8
    • Component/s: Appenders
    • Labels:
      None
    • Environment:

      Java 1.6_045.

      Description

      When I use a fast file appender it seems to start from the beginning of the file every time, overwriting previous entries. What I mean is that if the program starts, then I start again. The previous entries at the very beginning of the file are overwritten.

      It's possible that the fact that the entries span multiple lines might make it worse. Either way it always seems to start at the beginning of the file, instead of at the end (like log4j 1.2.x did).

      Maybe I need to try the regular file appender instead of the fast one and see if the same behavior occurs.

      I'm not at my workstation so I can't recreate it at the moment, but if you have trouble recreating it let me know.

        Attachments

        1. LOG4J-292.patch
          0.8 kB
          Thomas Neidhart

          Activity

            People

            • Assignee:
              remkop@yahoo.com Remko Popma
              Reporter:
              asaf.erlich Asaf Erlich
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: