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

Sifting appender unbounded timeout causes perpetual recreation of logs

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 1.0.13
    • logback-core

    Description

      When creating a sifting appender with a timeout of unbounded (Duration.buildUnbounded() or <timeout>9223372036854775807millis</timeout>) causes the appender to continually recreate logs.
      The error is on line 220 of AbstractComponentTracker. It returns "(entry.timestamp + timeout) < now". The issue is that when timeout is sufficiently high the difference becomes negative and hence will always be less than now. I am not entirely sure how to solve this. When unbounded is used, shouldn't the appender treat the logger as never being stale?

      Attachments

        Activity

          People

            logback-dev Logback dev list
            nmccloud Kenneth Gendron
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: