Uploaded image for project: 'Ambari'
  1. Ambari
  2. AMBARI-13248

Parallel library should process all futures even if one of them throws an exception

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 2.1.2
    • 2.1.2
    • ambari-agent, ambari-server
    • None

    Description

      • Parallel library should process all futures even if one of them throws an exception
      • Consider the case where we spawn 1000 future requests and the very 1st thread throws an exception.
      • Since the exception handling is outside the for loop we would end up returning a result with all nulls to the caller.
      • In getStagesInProgress() as a fall back we check the ParallelLoopResult and get all the missing results sequentially, so this could lead to the main thread and the spawned threads will process same requests in parallel and could lead to issues.

      Attachments

        Issue Links

          Activity

            People

              jluniya Jayush Luniya
              jluniya Jayush Luniya
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: