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

Code cleanup in ResourcePluginManager.initialize and in TestResourcePluginManager

    Details

    • Type: Improvement
    • Status: Patch Available
    • Priority: Trivial
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Some code cleanup is needed in ResourcePluginManager#initialize: 

      • There's a big code block that initializes resource plugins, this should be extracted to a separate method.
      • Exception handling could be simplified.

      TestResourcePluginManager minor cleanup: 

      • Not thrown exceptions could be deleted from method signatures
      • verify(obj, times(1)).<method>() calls: times(1) parameter could be deleted as it is the default if verify(obj) is invoked without the times parameter.
      • Some code exceeds the 80 character column limit.

        Attachments

        1. YARN-9140.002.patch
          17 kB
          Szilard Nemeth
        2. YARN-9140.001.patch
          17 kB
          Szilard Nemeth

          Activity

            People

            • Assignee:
              snemeth Szilard Nemeth
              Reporter:
              snemeth Szilard Nemeth
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: