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

FairScheduler: Incorrect calculation of amResource usage

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.5.0
    • Component/s: None
    • Labels:
      None
    • Target Version/s:
    • Hadoop Flags:
      Reviewed

      Description

      1. The amResource should be normalized instead of fetching from ApplicationSubmissionContext directly.

          ApplicationSubmissionContext appSubmissionContext =
              rmContext.getRMApps().get(applicationAttemptId.getApplicationId())
                  .getApplicationSubmissionContext();
          if (appSubmissionContext != null) {
              amResource = appSubmissionContext.getResource();
              unmanagedAM = appSubmissionContext.getUnmanagedAM();
          }
      

      2. When one application is removed, the FSLeafQueue's amResourceUsage should be updated only if the app has started its AM.

        if (runnableAppScheds.remove(app.getAppSchedulable())) {
            // Update AM resource usage
            if (app.getAMResource() != null) {
              Resources.subtractFrom(amResourceUsage, app.getAMResource());
            }
            return true;
        }
      

        Attachments

        1. YARN-2128.patch
          13 kB
          Wei Yan
        2. YARN-2128.patch
          5 kB
          Wei Yan

          Activity

            People

            • Assignee:
              ywskycn Wei Yan
              Reporter:
              ywskycn Wei Yan
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: