Uploaded image for project: 'Hadoop YARN'
  1. Hadoop YARN
  2. YARN-1128

FifoPolicy.computeShares throws NPE on empty list of Schedulables

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.1.0-beta
    • 2.2.0
    • scheduler
    • None
    • Reviewed

    Description

      FifoPolicy gives all of a queue's share to the earliest-scheduled application.

          Schedulable earliest = null;
          for (Schedulable schedulable : schedulables) {
            if (earliest == null ||
                schedulable.getStartTime() < earliest.getStartTime()) {
              earliest = schedulable;
            }
          }
          earliest.setFairShare(Resources.clone(totalResources));
      

      If the queue has no schedulables in it, earliest will be left null, leading to an NPE on the last line.

      Attachments

        1. yarn-1128-1.patch
          4 kB
          Karthik Kambatla

        Activity

          People

            kasha Karthik Kambatla
            sandyr Sandy Ryza
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: