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

Thread::sleep not affected by Thread::interrupt

    XMLWordPrintableJSON

    Details

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

      Description

      Spun off from LOGCXX-278. Thread::sleep() will call apr_sleep() which will unconditionally sleep for the specified time. The equivalent Java method will awake early and throw an InterruptedException if Thread::interrupt() is called. The current behavior means that shutdown has to wait until all sleeping threads complete their naps.

      Modifying Thread::sleep() to more closely mimic the Java equivalent will require viewing the current uses of Thread::sleep to make sure that the proper catch clauses are present.

        Attachments

        1. logcxx-282.patch
          9 kB
          Curt Arnold

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved: