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

SocketAppender queue thread never completes


    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 1.1.1
    • Fix Version/s: None
    • Labels:
    • Environment:

      on linux x86_64, though I doubt it is platform-specific


      There seems to be a deadlock which does not allow the SocketAppender to release its socket/thread resources.

      The attached code demonstrates this as follows:

      A simple socket server is booted on port 9867 for 2 minutes. Its configuration is set to write all received messages to a history.log, and internal ch.qos messages to server.log, at warn level.

      After a 3 second pause, the main test attempts to send an error message.
      The server exits after 2 minutes, but main in the test never completes.
      A thread dump shows that the problem seems to like in a thread pool wait
      (FutureTask which does not complete).

      This requires an explicit kill (cntrl-C) to make the shell script exit.

      Inspection of the history.log should reveal, however, that the message was sent and received successfully by the server.

      I note that there is no use of the java.util.concurrent.ThreadPoolExecutor in the previous version (1.0.12) ... not sure about 1.0.13.


          Issue Links



              • Assignee:
                logback-dev Logback dev list
                arossi Albert Louis Rossi
              • Votes:
                0 Vote for this issue
                2 Start watching this issue


                • Created: