Uploaded image for project: 'Oozie'
  1. Oozie
  2. OOZIE-3646

Possible dead-lock in SignalXCommand

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 5.3.0
    • None
    • None

    Description

      The limited thread execution mechanism aims to solve the dead-lock when all active threads are executing the SignalXCommand's invokeAll method.

      Dead-lock when to happen

      Assuming that Oozie CallableQueue thread pool size is 120, when all threads are executing the SignalXCommand.startForkedActions method, a deadlock occurs.
      Because in SignalXCommand.startForkedActions, the code of

      List<Future<ActionExecutorContext>> futures = Services.get().get(CallableQueueService.class)
                          .invokeAll(tasks);
      

      will be sync executed, however now all callableQueue threads are busy.

      Solution

      1. Need to limit directly invokeAll call when the num of rest threads is less than the tasks
      2. To obtain correct active threads number in callableQueue, the SignalXCommand.class lock is needed.

      Attachments

        1. OOZIE-3646-003.patch
          13 kB
          Junfan Zhang
        2. OOZIE-3646-002.patch
          12 kB
          Dénes Bodó
        3. OOZIE-3646.patch-2
          12 kB
          Junfan Zhang
        4. OOZIE-3646.patch-1
          12 kB
          Junfan Zhang
        5. a1.png
          627 kB
          Junfan Zhang

        Activity

          People

            zuston Junfan Zhang
            zuston Junfan Zhang
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: