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

Fix findbugs errors in hadoop-yarn-server-common module

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.8.0, 3.0.0-alpha1
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      7 findbugs warnings are found in hadoop-yarn-server-common module which needs to be fixed:

      [INFO]
      [INFO] --- findbugs-maven-plugin:3.0.0:findbugs (default-cli) @ hadoop-yarn-server-common ---
      [INFO] Fork Value is true
           [java] Warnings generated: 7
      [INFO] Done FindBugs Analysis....
      
      1. findbugs.xml
        3 kB
        MENG DING
      2. YARN-4151.1.patch
        5 kB
        MENG DING

        Activity

        Hide
        mding MENG DING added a comment -

        Attaching the findbugs report.

        Show
        mding MENG DING added a comment - Attaching the findbugs report.
        Hide
        mding MENG DING added a comment -

        Attaching the patch that addresses the findbugs warnings. Some of the warnings are introduced by YARN-4055 and YARN-3948

        I am not really sure if we need to fix the following though. We may still want to keep the branch as is, as different scheduler pages may have different column definitions for the cluster page.

        @@ -51,8 +51,7 @@ private static String getAppsTableColumnDefs(
             sb.append("[\n")
               .append("{'sType':'string', 'aTargets': [0]")
               .append(", 'mRender': parseHadoopID }")
        -      .append("\n, {'sType':'numeric', 'aTargets': " +
        -          (isFairSchedulerPage ? "[6, 7]": "[6, 7]"))
        +      .append("\n, {'sType':'numeric', 'aTargets': [6, 7]")
               .append(", 'mRender': renderHadoopDate }")
               .append("\n, {'sType':'numeric', bSearchable:false, 'aTargets':");
             if (isFairSchedulerPage) {
        
        Show
        mding MENG DING added a comment - Attaching the patch that addresses the findbugs warnings. Some of the warnings are introduced by YARN-4055 and YARN-3948 I am not really sure if we need to fix the following though. We may still want to keep the branch as is, as different scheduler pages may have different column definitions for the cluster page. @@ -51,8 +51,7 @@ private static String getAppsTableColumnDefs( sb.append( "[\n" ) .append( "{'sType':'string', 'aTargets': [0]" ) .append( ", 'mRender': parseHadoopID }" ) - .append( "\n, {'sType':'numeric', 'aTargets': " + - (isFairSchedulerPage ? "[6, 7]" : "[6, 7]" )) + .append( "\n, {'sType':'numeric', 'aTargets': [6, 7]" ) .append( ", 'mRender': renderHadoopDate }" ) .append( "\n, {'sType':'numeric', bSearchable: false , 'aTargets':" ); if (isFairSchedulerPage) {
        Hide
        hadoopqa Hadoop QA added a comment -



        -1 overall



        Vote Subsystem Runtime Comment
        -1 pre-patch 16m 13s Pre-patch trunk has 7 extant Findbugs (version 3.0.0) warnings.
        +1 @author 0m 0s The patch does not contain any @author tags.
        -1 tests included 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
        +1 javac 7m 49s There were no new javac warning messages.
        +1 javadoc 10m 6s There were no new javadoc warning messages.
        +1 release audit 0m 22s The applied patch does not increase the total number of release audit warnings.
        +1 checkstyle 0m 33s There were no new checkstyle issues.
        +1 whitespace 0m 0s The patch has no lines that end in whitespace.
        +1 install 1m 29s mvn install still works.
        +1 eclipse:eclipse 0m 32s The patch built with eclipse:eclipse.
        +1 findbugs 1m 3s The patch does not introduce any new Findbugs (version 3.0.0) warnings, and fixes 7 pre-existing warnings.
        +1 yarn tests 0m 25s Tests passed in hadoop-yarn-server-common.
            38m 35s  



        Subsystem Report/Notes
        Patch URL http://issues.apache.org/jira/secure/attachment/12755799/YARN-4151.1.patch
        Optional Tests javadoc javac unit findbugs checkstyle
        git revision trunk / 6955771
        Pre-patch Findbugs warnings https://builds.apache.org/job/PreCommit-YARN-Build/9130/artifact/patchprocess/trunkFindbugsWarningshadoop-yarn-server-common.html
        hadoop-yarn-server-common test log https://builds.apache.org/job/PreCommit-YARN-Build/9130/artifact/patchprocess/testrun_hadoop-yarn-server-common.txt
        Test Results https://builds.apache.org/job/PreCommit-YARN-Build/9130/testReport/
        Java 1.7.0_55
        uname Linux asf907.gq1.ygridcore.net 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
        Console output https://builds.apache.org/job/PreCommit-YARN-Build/9130/console

        This message was automatically generated.

        Show
        hadoopqa Hadoop QA added a comment - -1 overall Vote Subsystem Runtime Comment -1 pre-patch 16m 13s Pre-patch trunk has 7 extant Findbugs (version 3.0.0) warnings. +1 @author 0m 0s The patch does not contain any @author tags. -1 tests included 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 javac 7m 49s There were no new javac warning messages. +1 javadoc 10m 6s There were no new javadoc warning messages. +1 release audit 0m 22s The applied patch does not increase the total number of release audit warnings. +1 checkstyle 0m 33s There were no new checkstyle issues. +1 whitespace 0m 0s The patch has no lines that end in whitespace. +1 install 1m 29s mvn install still works. +1 eclipse:eclipse 0m 32s The patch built with eclipse:eclipse. +1 findbugs 1m 3s The patch does not introduce any new Findbugs (version 3.0.0) warnings, and fixes 7 pre-existing warnings. +1 yarn tests 0m 25s Tests passed in hadoop-yarn-server-common.     38m 35s   Subsystem Report/Notes Patch URL http://issues.apache.org/jira/secure/attachment/12755799/YARN-4151.1.patch Optional Tests javadoc javac unit findbugs checkstyle git revision trunk / 6955771 Pre-patch Findbugs warnings https://builds.apache.org/job/PreCommit-YARN-Build/9130/artifact/patchprocess/trunkFindbugsWarningshadoop-yarn-server-common.html hadoop-yarn-server-common test log https://builds.apache.org/job/PreCommit-YARN-Build/9130/artifact/patchprocess/testrun_hadoop-yarn-server-common.txt Test Results https://builds.apache.org/job/PreCommit-YARN-Build/9130/testReport/ Java 1.7.0_55 uname Linux asf907.gq1.ygridcore.net 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux Console output https://builds.apache.org/job/PreCommit-YARN-Build/9130/console This message was automatically generated.
        Hide
        mding MENG DING added a comment -

        This patch fixes findbugs warnings, so no test cases are added.

        Show
        mding MENG DING added a comment - This patch fixes findbugs warnings, so no test cases are added.
        Hide
        leftnoteasy Wangda Tan added a comment -

        LGTM, committing...

        Show
        leftnoteasy Wangda Tan added a comment - LGTM, committing...
        Hide
        leftnoteasy Wangda Tan added a comment -

        Committed to trunk/branch-2, thanks MENG DING!

        Show
        leftnoteasy Wangda Tan added a comment - Committed to trunk/branch-2, thanks MENG DING !
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Hadoop-trunk-Commit #8450 (See https://builds.apache.org/job/Hadoop-trunk-Commit/8450/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Hadoop-trunk-Commit #8450 (See https://builds.apache.org/job/Hadoop-trunk-Commit/8450/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Hadoop-Yarn-trunk-Java8 #391 (See https://builds.apache.org/job/Hadoop-Yarn-trunk-Java8/391/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Hadoop-Yarn-trunk-Java8 #391 (See https://builds.apache.org/job/Hadoop-Yarn-trunk-Java8/391/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Hadoop-Mapreduce-trunk-Java8 #385 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Java8/385/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Mapreduce-trunk-Java8 #385 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Java8/385/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Hadoop-Yarn-trunk #1124 (See https://builds.apache.org/job/Hadoop-Yarn-trunk/1124/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Hadoop-Yarn-trunk #1124 (See https://builds.apache.org/job/Hadoop-Yarn-trunk/1124/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Hadoop-Mapreduce-trunk #2333 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/2333/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Mapreduce-trunk #2333 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/2333/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Hadoop-Hdfs-trunk #2310 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/2310/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/CHANGES.txt
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Hdfs-trunk #2310 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/2310/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/CHANGES.txt hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Hadoop-Hdfs-trunk-Java8 #370 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/370/)
        YARN-4151. Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2)

        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java
        • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java
        • hadoop-yarn-project/CHANGES.txt
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Hdfs-trunk-Java8 #370 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/370/ ) YARN-4151 . Fix findbugs errors in hadoop-yarn-server-common module. (Meng Ding via wangda) (wangda: rev e2a02702178db60150cc0c2253d48b8532a474c2) hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/api/records/impl/pb/NodeStatusPBImpl.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebServices.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/webapp/WebPageUtils.java hadoop-yarn-project/CHANGES.txt

          People

          • Assignee:
            mding MENG DING
            Reporter:
            mding MENG DING
          • Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development