Uploaded image for project: 'Log4cxx'
  1. Log4cxx
  2. LOGCXX-257

ServerSocket::accept hangs on Unix

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.10.0
    • Component/s: Appender
    • Labels:
      None

      Description

      ServerSocket::accept will not time out on Unix which would result in a call to TelnetAppender::close() or SocketHubAppender::close() stalling waiting to join with the connection monitoring thread. The problem appears to be inconsistent behavior of blocking socket IO with timeout between platforms.

      To address the problem, ServerSocket was rewritten to use non-blocking IO with polling. ServerSocket and Socket were essentially wrappers around SocketImpl. With the change of ServerSocket to use non-blocking IO, it was expedient to remove SocketImpl and to split the appropriate parts between ServerSocket and Socket and remove unused code like Socket::read.

        Attachments

          Activity

            People

            • Assignee:
              carnold@apache.org Curt Arnold
              Reporter:
              carnold@apache.org Curt Arnold
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: