Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-35714

Bug fix for deadlock during the executor shutdown

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1.2
    • Fix Version/s: 3.0.3, 3.2.0, 3.1.3
    • Component/s: Spark Core
    • Labels:
      None

      Description

      When a executor received a TERM signal, it (the second TERM signal) will lock java.lang.Shutdown class and then call Shutdown.exit() method to exit the JVM.
      Shutdown will call SparkShutdownHook to shutdown the executor.
      During the executor shutdown phase, RemoteProcessDisconnected event will be send to the RPC inbox, and then WorkerWatcher will try to call System.exit(-1) again.
      Because java.lang.Shutdown has already locked, a deadlock has occurred.

        Attachments

        1. three_thread_lock.log
          14 kB
          Wan Kun

          Activity

            People

            • Assignee:
              wankun Wan Kun
              Reporter:
              wankun Wan Kun
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: