Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-19046

myTerminate terminate handler self deadlocks when re-entered

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.1.5
    • Component/s: Internal Code
    • Labels:
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Sprint:
      Sharding 5 06/26/16

      Description

      If terminate is called from within the terminate handler, as can happen in some runtimes when trying to deduce the runtime type of an active exception within myTerminate, the re-entered invocation of myTerminate deadlocks on the streamMutex.

      The fix is to make myTerminate immediately call quickExit when it is re-entered in the same thread. We want to keep the existing behavior that other threads simultaneously entering myTerminate block indefinitely on the stream mutex, so that the first caller of terminate gets ample time to write messages to the logs.

        Attachments

          Activity

            People

            Assignee:
            schwerin Andy Schwerin
            Reporter:
            schwerin Andy Schwerin
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: