Hadoop HDFS
  1. Hadoop HDFS
  2. HDFS-2023

Backport of NPE for File.list and File.listFiles

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.20.205.0
    • Fix Version/s: 0.20.204.0
    • Component/s: datanode
    • Labels:
      None

      Description

      Since we have multiple Jira's in trunk for common and hdfs, I am creating another jira for this issue.

      This patch addresses the following:

      1. Provides FileUtil API for list and listFiles which throws IOException for null cases.
      2. Replaces most of the code where JDK file API with FileUtil API.

      1. HDFS-2023-1.patch
        9 kB
        Bharath Mundlapudi

        Issue Links

          Activity

          Hide
          Bharath Mundlapudi added a comment -

          Attaching a patch for this issue.

          Show
          Bharath Mundlapudi added a comment - Attaching a patch for this issue.
          Hide
          Eli Collins added a comment -

          In the future how about using multiple fix versions on the original jira so we don't have different jira numbers for the same change? Ie we don't have multiple jiras for an issue that goes into both 0.23 and 0.22, so no need for a jira going into 0.23 and 0.20.205.

          Show
          Eli Collins added a comment - In the future how about using multiple fix versions on the original jira so we don't have different jira numbers for the same change? Ie we don't have multiple jiras for an issue that goes into both 0.23 and 0.22, so no need for a jira going into 0.23 and 0.20.205.
          Hide
          Bharath Mundlapudi added a comment -

          Hi Eli,

          I wanted to have this change in the same Jira as 0.23 but those were reviewed and committed. So I created this one. Also, i could have done multiple patches in those same Jiras but this will be not good for reviwers. On the positive side, we can have this single Jira for all 0.20.*.

          But i agree with you on having same Jira for backporting.

          Show
          Bharath Mundlapudi added a comment - Hi Eli, I wanted to have this change in the same Jira as 0.23 but those were reviewed and committed. So I created this one. Also, i could have done multiple patches in those same Jiras but this will be not good for reviwers. On the positive side, we can have this single Jira for all 0.20.*. But i agree with you on having same Jira for backporting.
          Hide
          Matt Foley added a comment -

          Eli, I asked Bharath to make a separate Jira, because this set of changes isn't the same content as the previously existing Jiras. Granted he could split this into the same four chunks as represented by HADOOP-7342, HADOOP-7322, HDFS-1934, and HDFS-2019. But it seemed more efficient to do them together for v20, since there is no HADOOP/HDFS split.

          Do you prefer to have four patches instead of one?

          Show
          Matt Foley added a comment - Eli, I asked Bharath to make a separate Jira, because this set of changes isn't the same content as the previously existing Jiras. Granted he could split this into the same four chunks as represented by HADOOP-7342 , HADOOP-7322 , HDFS-1934 , and HDFS-2019 . But it seemed more efficient to do them together for v20, since there is no HADOOP/HDFS split. Do you prefer to have four patches instead of one?
          Hide
          Eli Collins added a comment -

          I don't feel strongly. It's easier for users if the same issue is represented by a single jira across versions (you'll see a patch for different branches on the same jira) but if the content is different (not the patch but different goal/change) then a new jira makes sense.

          Show
          Eli Collins added a comment - I don't feel strongly. It's easier for users if the same issue is represented by a single jira across versions (you'll see a patch for different branches on the same jira) but if the content is different (not the patch but different goal/change) then a new jira makes sense.
          Hide
          Matt Foley added a comment -

          +1 for code review, pending local test-patch results.

          Show
          Matt Foley added a comment - +1 for code review, pending local test-patch results.
          Hide
          Bharath Mundlapudi added a comment -

          I have run local test-patch on this patch and here are the results for this branch. -1s are not related to this patch.

          [exec] -1 overall.
          [exec]
          [exec] +1 @author. The patch does not contain any @author tags.
          [exec]
          [exec] +1 tests included. The patch appears to include 9 new or modified tests.
          [exec]
          [exec] -1 javadoc. The javadoc tool appears to have generated 1 warning messages.
          [exec]
          [exec] +1 javac. The applied patch does not increase the total number of javac compiler warnings.
          [exec]
          [exec] +1 findbugs. The patch does not introduce any new Findbugs warnings.
          [exec]
          [exec] -1 Eclipse classpath. The patch causes the Eclipse classpath to differ from the contents of the lib directories.

          Javadoc 6 warnings and Eclipse classpath are not related to this patch.

          --------------------------------------------------------------------
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:36: warning: sun.security.jgss.krb5.Krb5Util
          is Sun proprietary API and may be removed in a future release
          [javadoc] import sun.security.jgss.krb5.Krb5Util;
          [javadoc] ^
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:37: warning: sun.security.krb5.Credentials is
          Sun proprietary API and may be removed in a future release
          [javadoc] import sun.security.krb5.Credentials;
          [javadoc] ^
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:38: warning: sun.security.krb5.PrincipalName
          is Sun proprietary API and may be removed in a future release
          [javadoc] import sun.security.krb5.PrincipalName;
          [javadoc] ^
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:29: warning: sun.security.krb5.Config is Sun
          proprietary API and may be removed in a future release
          [javadoc] import sun.security.krb5.Config;
          [javadoc] ^
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:30: warning: sun.security.krb5.KrbException i
          s Sun proprietary API and may be removed in a future release
          [javadoc] import sun.security.krb5.KrbException;
          [javadoc] ^
          [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:76: warning: sun.security.krb5.Config is Sun proprietary API and may be removed in a future release
          [javadoc] private static Config kerbConf;
          [javadoc] ^
          [javadoc] Standard Doclet version 1.6.0_17
          [javadoc] Building tree for all the packages and classes...
          [javadoc] Building index for all the packages and classes...
          [javadoc] Building index for all classes...
          [javadoc] Generating /export/space/branch-0.20-security.qa/hadoop-common/build/docs/api/stylesheet.css...
          [javadoc] 6 warnings

          ---------------------------------------------------------------

          Show
          Bharath Mundlapudi added a comment - I have run local test-patch on this patch and here are the results for this branch. -1s are not related to this patch. [exec] -1 overall. [exec] [exec] +1 @author. The patch does not contain any @author tags. [exec] [exec] +1 tests included. The patch appears to include 9 new or modified tests. [exec] [exec] -1 javadoc. The javadoc tool appears to have generated 1 warning messages. [exec] [exec] +1 javac. The applied patch does not increase the total number of javac compiler warnings. [exec] [exec] +1 findbugs. The patch does not introduce any new Findbugs warnings. [exec] [exec] -1 Eclipse classpath. The patch causes the Eclipse classpath to differ from the contents of the lib directories. Javadoc 6 warnings and Eclipse classpath are not related to this patch. -------------------------------------------------------------------- [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:36: warning: sun.security.jgss.krb5.Krb5Util is Sun proprietary API and may be removed in a future release [javadoc] import sun.security.jgss.krb5.Krb5Util; [javadoc] ^ [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:37: warning: sun.security.krb5.Credentials is Sun proprietary API and may be removed in a future release [javadoc] import sun.security.krb5.Credentials; [javadoc] ^ [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/SecurityUtil.java:38: warning: sun.security.krb5.PrincipalName is Sun proprietary API and may be removed in a future release [javadoc] import sun.security.krb5.PrincipalName; [javadoc] ^ [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:29: warning: sun.security.krb5.Config is Sun proprietary API and may be removed in a future release [javadoc] import sun.security.krb5.Config; [javadoc] ^ [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:30: warning: sun.security.krb5.KrbException i s Sun proprietary API and may be removed in a future release [javadoc] import sun.security.krb5.KrbException; [javadoc] ^ [javadoc] /export/space/branch-0.20-security.qa/hadoop-common/src/core/org/apache/hadoop/security/KerberosName.java:76: warning: sun.security.krb5.Config is Sun proprietary API and may be removed in a future release [javadoc] private static Config kerbConf; [javadoc] ^ [javadoc] Standard Doclet version 1.6.0_17 [javadoc] Building tree for all the packages and classes... [javadoc] Building index for all the packages and classes... [javadoc] Building index for all classes... [javadoc] Generating /export/space/branch-0.20-security.qa/hadoop-common/build/docs/api/stylesheet.css... [javadoc] 6 warnings ---------------------------------------------------------------
          Hide
          Matt Foley added a comment -

          Committed to 0.20-security. Thanks Bharath!

          Show
          Matt Foley added a comment - Committed to 0.20-security. Thanks Bharath!
          Hide
          Owen O'Malley added a comment -

          Hadoop 0.20.204.0 was released.

          Show
          Owen O'Malley added a comment - Hadoop 0.20.204.0 was released.

            People

            • Assignee:
              Bharath Mundlapudi
              Reporter:
              Bharath Mundlapudi
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development