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

getTransferredContainers in AbstractYarnScheduler should be present in YarnScheduler interface instead

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.0
    • Fix Version/s: 2.8.0, 3.0.0-alpha1
    • Component/s: scheduler
    • Labels:
      None
    • Target Version/s:

      Description

      Currently getTransferredContainers is present in AbstractYarnScheduler.
      But in ApplicationMasterService, while registering AM, we are calling this method by typecasting it to AbstractYarnScheduler, which is incorrect.

      This method should be moved to YarnScheduler.

      Because if a custom scheduler is to be added, it will implement YarnScheduler, not AbstractYarnScheduler.
      As ApplicationMasterService is calling getTransferredContainers by typecasting it to AbstractYarnScheduler, it is imposing an indirect dependency on AbstractYarnScheduler for any pluggable custom scheduler.

      We can move the method to YarnScheduler and leave the definition in AbstractYarnScheduler as it is.

        Attachments

        1. YARN-3986.03.patch
          5 kB
          Varun Saxena
        2. YARN-3986.02.patch
          5 kB
          Varun Saxena
        3. YARN-3986.01.patch
          4 kB
          Varun Saxena

          Issue Links

            Activity

              People

              • Assignee:
                varun_saxena Varun Saxena
                Reporter:
                varun_saxena Varun Saxena
              • Votes:
                0 Vote for this issue
                Watchers:
                10 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: