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

Async appenders do not scale well across multiple threads

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2.1
    • Fix Version/s: 1.3.0-alpha6
    • Component/s: logback-classic
    • Labels:
      None

      Description

      When running some benchmarking (specifically https://github.com/stephenc/java-logging-benchmarks/blob/master/log4j-fmt/logback-async/src/main/java/me/justpitch/loggingbenchmarks/LoggingBenchmark.java - at time of issue creation @ceki has access to repo, but repo is due to become public soon) I noticed that the Async appender does not scale well when the number of threads increases.

      In fact the Async appender - which to my understanding is designed to help provide a more consistent latency under multiple threads - has dire performance when the number of threads increase, e.g.

      The above results show that Log4J with an async appender has a profile very similar to that of both Logback and Log4J with a non-asynchronous appender. Logback's asynchronous appender performance gets progressively worse and approximates the performance of Java Utils Logging above 16 threads on the test system

        Attachments

          Activity

            People

            • Assignee:
              ceki Ceki Gülcü
              Reporter:
              stephenc Stephen Connolly
            • Votes:
              6 Vote for this issue
              Watchers:
              11 Start watching this issue

              Dates

              • Created:
                Updated: