Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.8.0, 3.0.0-alpha2
    • Component/s: None
    • Labels:
    • Hadoop Flags:
      Reviewed

      Description

      FSImage.java
          Exception le = null;
          FSImageFile imageFile = null;
          for (int i = 0; i < imageFiles.size(); i++) {
            try {
              imageFile = imageFiles.get(i);
              loadFSImageFile(target, recovery, imageFile, startOpt);
              break;
            } catch (IllegalReservedPathException ie) {
              throw new IOException("Failed to load image from " + imageFile,
                  ie);
            } catch (Exception e) {
              le = e;
              LOG.error("Failed to load image from " + imageFile, e);
              target.clear();
              imageFile = null;
            }
          }
      

      Exception le is not used. It can be removed.

      1. HDFS-11262_00.patch
        0.9 kB
        Jagadesh Kiran N
      2. HDFS-11262_01.patch
        1 kB
        Jagadesh Kiran N
      3. HDFS-11262_02.patch
        1 kB
        Jagadesh Kiran N

        Activity

        Hide
        jagadesh.kiran Jagadesh Kiran N added a comment -

        Attaching the patch please review

        Show
        jagadesh.kiran Jagadesh Kiran N added a comment - Attaching the patch please review
        Hide
        ajisakaa Akira Ajisaka added a comment -

        Hi Jagadesh Kiran N, would you remove Exception le = null; as well?

        Show
        ajisakaa Akira Ajisaka added a comment - Hi Jagadesh Kiran N , would you remove Exception le = null; as well?
        Hide
        jagadesh.kiran Jagadesh Kiran N added a comment -

        Thanks Akira Ajisaka for review, updated the patch please review

        Show
        jagadesh.kiran Jagadesh Kiran N added a comment - Thanks Akira Ajisaka for review, updated the patch please review
        Hide
        jagadesh.kiran Jagadesh Kiran N added a comment -

        private int quotaInitThreads; this variable also not used,please check

        Show
        jagadesh.kiran Jagadesh Kiran N added a comment - private int quotaInitThreads; this variable also not used,please check
        Hide
        ajisakaa Akira Ajisaka added a comment -

        Nice catch! Yes, it should be removed.

        Show
        ajisakaa Akira Ajisaka added a comment - Nice catch! Yes, it should be removed.
        Hide
        jagadesh.kiran Jagadesh Kiran N added a comment -

        Updated the patch,please review

        Show
        jagadesh.kiran Jagadesh Kiran N added a comment - Updated the patch,please review
        Hide
        ajisakaa Akira Ajisaka added a comment -

        +1 pending Jenkins.

        Show
        ajisakaa Akira Ajisaka added a comment - +1 pending Jenkins.
        Hide
        hadoopqa Hadoop QA added a comment -
        -1 overall



        Vote Subsystem Runtime Comment
        0 reexec 0m 10s Docker mode activated.
        +1 @author 0m 0s The patch does not contain any @author tags.
        -1 test4tests 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 mvninstall 12m 38s trunk passed
        +1 compile 0m 45s trunk passed
        +1 checkstyle 0m 26s trunk passed
        +1 mvnsite 0m 49s trunk passed
        +1 mvneclipse 0m 13s trunk passed
        +1 findbugs 1m 40s trunk passed
        +1 javadoc 0m 39s trunk passed
        +1 mvninstall 0m 45s the patch passed
        +1 compile 0m 42s the patch passed
        +1 javac 0m 42s the patch passed
        +1 checkstyle 0m 22s the patch passed
        +1 mvnsite 0m 49s the patch passed
        +1 mvneclipse 0m 10s the patch passed
        +1 whitespace 0m 0s The patch has no whitespace issues.
        +1 findbugs 1m 48s the patch passed
        +1 javadoc 0m 37s the patch passed
        +1 unit 61m 31s hadoop-hdfs in the patch passed.
        +1 asflicense 0m 19s The patch does not generate ASF License warnings.
        85m 31s



        Subsystem Report/Notes
        Docker Image:yetus/hadoop:a9ad5d6
        JIRA Issue HDFS-11262
        JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12843930/HDFS-11262_01.patch
        Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle
        uname Linux 35f58613ec62 3.13.0-93-generic #140-Ubuntu SMP Mon Jul 18 21:21:05 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
        Build tool maven
        Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh
        git revision trunk / ef2dd7b
        Default Java 1.8.0_111
        findbugs v3.0.0
        Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/17896/testReport/
        modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
        Console output https://builds.apache.org/job/PreCommit-HDFS-Build/17896/console
        Powered by Apache Yetus 0.5.0-SNAPSHOT http://yetus.apache.org

        This message was automatically generated.

        Show
        hadoopqa Hadoop QA added a comment - -1 overall Vote Subsystem Runtime Comment 0 reexec 0m 10s Docker mode activated. +1 @author 0m 0s The patch does not contain any @author tags. -1 test4tests 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 mvninstall 12m 38s trunk passed +1 compile 0m 45s trunk passed +1 checkstyle 0m 26s trunk passed +1 mvnsite 0m 49s trunk passed +1 mvneclipse 0m 13s trunk passed +1 findbugs 1m 40s trunk passed +1 javadoc 0m 39s trunk passed +1 mvninstall 0m 45s the patch passed +1 compile 0m 42s the patch passed +1 javac 0m 42s the patch passed +1 checkstyle 0m 22s the patch passed +1 mvnsite 0m 49s the patch passed +1 mvneclipse 0m 10s the patch passed +1 whitespace 0m 0s The patch has no whitespace issues. +1 findbugs 1m 48s the patch passed +1 javadoc 0m 37s the patch passed +1 unit 61m 31s hadoop-hdfs in the patch passed. +1 asflicense 0m 19s The patch does not generate ASF License warnings. 85m 31s Subsystem Report/Notes Docker Image:yetus/hadoop:a9ad5d6 JIRA Issue HDFS-11262 JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12843930/HDFS-11262_01.patch Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle uname Linux 35f58613ec62 3.13.0-93-generic #140-Ubuntu SMP Mon Jul 18 21:21:05 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux Build tool maven Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh git revision trunk / ef2dd7b Default Java 1.8.0_111 findbugs v3.0.0 Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/17896/testReport/ modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs Console output https://builds.apache.org/job/PreCommit-HDFS-Build/17896/console Powered by Apache Yetus 0.5.0-SNAPSHOT http://yetus.apache.org This message was automatically generated.
        Hide
        hadoopqa Hadoop QA added a comment -
        -1 overall



        Vote Subsystem Runtime Comment
        0 reexec 0m 11s Docker mode activated.
        +1 @author 0m 0s The patch does not contain any @author tags.
        -1 test4tests 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 mvninstall 23m 57s trunk passed
        +1 compile 0m 45s trunk passed
        +1 checkstyle 0m 26s trunk passed
        +1 mvnsite 0m 50s trunk passed
        +1 mvneclipse 0m 13s trunk passed
        +1 findbugs 1m 42s trunk passed
        +1 javadoc 0m 39s trunk passed
        +1 mvninstall 0m 43s the patch passed
        +1 compile 0m 42s the patch passed
        +1 javac 0m 42s the patch passed
        +1 checkstyle 0m 23s the patch passed
        +1 mvnsite 0m 48s the patch passed
        +1 mvneclipse 0m 10s the patch passed
        +1 whitespace 0m 0s The patch has no whitespace issues.
        +1 findbugs 1m 47s the patch passed
        +1 javadoc 0m 37s the patch passed
        -1 unit 73m 33s hadoop-hdfs in the patch failed.
        +1 asflicense 0m 20s The patch does not generate ASF License warnings.
        108m 58s



        Reason Tests
        Failed junit tests hadoop.hdfs.server.namenode.TestNameNodeMetadataConsistency
          hadoop.hdfs.server.datanode.checker.TestThrottledAsyncChecker



        Subsystem Report/Notes
        Docker Image:yetus/hadoop:a9ad5d6
        JIRA Issue HDFS-11262
        JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12843934/HDFS-11262_02.patch
        Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle
        uname Linux 8a0a7f214b33 3.13.0-95-generic #142-Ubuntu SMP Fri Aug 12 17:00:09 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
        Build tool maven
        Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh
        git revision trunk / ef2dd7b
        Default Java 1.8.0_111
        findbugs v3.0.0
        unit https://builds.apache.org/job/PreCommit-HDFS-Build/17897/artifact/patchprocess/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
        Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/17897/testReport/
        modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
        Console output https://builds.apache.org/job/PreCommit-HDFS-Build/17897/console
        Powered by Apache Yetus 0.5.0-SNAPSHOT http://yetus.apache.org

        This message was automatically generated.

        Show
        hadoopqa Hadoop QA added a comment - -1 overall Vote Subsystem Runtime Comment 0 reexec 0m 11s Docker mode activated. +1 @author 0m 0s The patch does not contain any @author tags. -1 test4tests 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 mvninstall 23m 57s trunk passed +1 compile 0m 45s trunk passed +1 checkstyle 0m 26s trunk passed +1 mvnsite 0m 50s trunk passed +1 mvneclipse 0m 13s trunk passed +1 findbugs 1m 42s trunk passed +1 javadoc 0m 39s trunk passed +1 mvninstall 0m 43s the patch passed +1 compile 0m 42s the patch passed +1 javac 0m 42s the patch passed +1 checkstyle 0m 23s the patch passed +1 mvnsite 0m 48s the patch passed +1 mvneclipse 0m 10s the patch passed +1 whitespace 0m 0s The patch has no whitespace issues. +1 findbugs 1m 47s the patch passed +1 javadoc 0m 37s the patch passed -1 unit 73m 33s hadoop-hdfs in the patch failed. +1 asflicense 0m 20s The patch does not generate ASF License warnings. 108m 58s Reason Tests Failed junit tests hadoop.hdfs.server.namenode.TestNameNodeMetadataConsistency   hadoop.hdfs.server.datanode.checker.TestThrottledAsyncChecker Subsystem Report/Notes Docker Image:yetus/hadoop:a9ad5d6 JIRA Issue HDFS-11262 JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12843934/HDFS-11262_02.patch Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle uname Linux 8a0a7f214b33 3.13.0-95-generic #142-Ubuntu SMP Fri Aug 12 17:00:09 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux Build tool maven Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh git revision trunk / ef2dd7b Default Java 1.8.0_111 findbugs v3.0.0 unit https://builds.apache.org/job/PreCommit-HDFS-Build/17897/artifact/patchprocess/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/17897/testReport/ modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs Console output https://builds.apache.org/job/PreCommit-HDFS-Build/17897/console Powered by Apache Yetus 0.5.0-SNAPSHOT http://yetus.apache.org This message was automatically generated.
        Hide
        ajisakaa Akira Ajisaka added a comment -

        These test failures are not related, checking this in.

        Show
        ajisakaa Akira Ajisaka added a comment - These test failures are not related, checking this in.
        Hide
        ajisakaa Akira Ajisaka added a comment -

        Committed this to trunk, branch-2, and branch-2.8. Thanks Jagadesh Kiran N for the contribution.

        Show
        ajisakaa Akira Ajisaka added a comment - Committed this to trunk, branch-2, and branch-2.8. Thanks Jagadesh Kiran N for the contribution.
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #11013 (See https://builds.apache.org/job/Hadoop-trunk-Commit/11013/)
        HDFS-11262. Remove unused variables in FSImage.java. Contributed by (aajisaka: rev d2026ae9e6c86f4fd9e48b80e71233181c1853d9)

        • (edit) hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #11013 (See https://builds.apache.org/job/Hadoop-trunk-Commit/11013/ ) HDFS-11262 . Remove unused variables in FSImage.java. Contributed by (aajisaka: rev d2026ae9e6c86f4fd9e48b80e71233181c1853d9) (edit) hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
        Hide
        jagadesh.kiran Jagadesh Kiran N added a comment -

        Thanks Akira Ajisaka for committing the same

        Show
        jagadesh.kiran Jagadesh Kiran N added a comment - Thanks Akira Ajisaka for committing the same

          People

          • Assignee:
            jagadesh.kiran Jagadesh Kiran N
            Reporter:
            ajisakaa Akira Ajisaka
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development