Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-12162

Update listStatus document to describe the behavior when the argument is a file

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0-beta1
    • Component/s: hdfs, httpfs
    • Labels:
      None

      Description

      The listStatus method can take in either directory path or file path as input, however, currently both the javadoc and external document describe it as only taking directory as input. This jira is to update the document about the behavior when the argument is a file path.

      Thanks Xiao Chen for the review and discussion in HDFS-12139, creating this jira is the result of our discussion there.

      1. HDFS-12162.01.patch
        3 kB
        Ajay Kumar
      2. Screen Shot 2017-08-03 at 11.01.46 AM.png
        524 kB
        Ajay Kumar
      3. Screen Shot 2017-08-03 at 11.02.19 AM.png
        222 kB
        Ajay Kumar

        Issue Links

          Activity

          Hide
          ajayydv Ajay Kumar added a comment - - edited

          Yongjun Zhang,Anu Engineer,Elek, Marton thanks for review and commit.
          Created follow up jira (HDFS-12542) to fix javadoc. Seems documentation for directory listing is little outdated as well. Will address both in new jira.

          Show
          ajayydv Ajay Kumar added a comment - - edited Yongjun Zhang , Anu Engineer , Elek, Marton thanks for review and commit. Created follow up jira ( HDFS-12542 ) to fix javadoc. Seems documentation for directory listing is little outdated as well. Will address both in new jira.
          Hide
          yzhangal Yongjun Zhang added a comment -

          Thanks for working on this Ajay Kumar and Anu Engineer.

          Sorry I was not on top of this. There are also javadocs, all listStatus methods only talk about directory but not file. Maybe we can create a follow-up jira to fix those.

          Thanks.

          Show
          yzhangal Yongjun Zhang added a comment - Thanks for working on this Ajay Kumar and Anu Engineer . Sorry I was not on top of this. There are also javadocs, all listStatus methods only talk about directory but not file. Maybe we can create a follow-up jira to fix those. Thanks.
          Hide
          hudson Hudson added a comment -

          SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #12180 (See https://builds.apache.org/job/Hadoop-trunk-Commit/12180/)
          HDFS-12162. Update listStatus document to describe the behavior when the (aengineer: rev d72124a44268e21ada036242bfbccafc23c52ed0)

          • (edit) hadoop-hdfs-project/hadoop-hdfs/src/site/markdown/WebHDFS.md
          • (edit) hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/java/org/apache/hadoop/fs/http/server/FSOperations.java
          Show
          hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #12180 (See https://builds.apache.org/job/Hadoop-trunk-Commit/12180/ ) HDFS-12162 . Update listStatus document to describe the behavior when the (aengineer: rev d72124a44268e21ada036242bfbccafc23c52ed0) (edit) hadoop-hdfs-project/hadoop-hdfs/src/site/markdown/WebHDFS.md (edit) hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/java/org/apache/hadoop/fs/http/server/FSOperations.java
          Hide
          anu Anu Engineer added a comment -

          Elek, Marton Thanks for the review. Ajay Kumar Thank you for contribution. I have committed this change to trunk.

          Show
          anu Anu Engineer added a comment - Elek, Marton Thanks for the review. Ajay Kumar Thank you for contribution. I have committed this change to trunk.
          Hide
          anu Anu Engineer added a comment -

          +1, I will commit this shortly. Thanks for the contribution.

          Show
          anu Anu Engineer added a comment - +1, I will commit this shortly. Thanks for the contribution.
          Hide
          elek Elek, Marton added a comment -

          LGTM. I just tested HDFS-12139 patch, and REST call worked as the patch wrote it.

          Show
          elek Elek, Marton added a comment - LGTM. I just tested HDFS-12139 patch, and REST call worked as the patch wrote it.
          Hide
          hadoopqa Hadoop QA added a comment -
          -1 overall



          Vote Subsystem Runtime Comment
          0 reexec 0m 14s Docker mode activated.
                Prechecks
          +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.
                trunk Compile Tests
          0 mvndep 0m 23s Maven dependency ordering for branch
          +1 mvninstall 13m 48s trunk passed
          +1 compile 1m 29s trunk passed
          +1 checkstyle 0m 40s trunk passed
          +1 mvnsite 2m 4s trunk passed
          -1 findbugs 1m 40s hadoop-hdfs-project/hadoop-hdfs in trunk has 9 extant Findbugs warnings.
          +1 javadoc 0m 55s trunk passed
                Patch Compile Tests
          0 mvndep 0m 7s Maven dependency ordering for patch
          +1 mvninstall 1m 6s the patch passed
          +1 compile 1m 25s the patch passed
          +1 javac 1m 25s the patch passed
          +1 checkstyle 0m 38s the patch passed
          +1 mvnsite 1m 59s the patch passed
          +1 whitespace 0m 0s The patch has no whitespace issues.
          +1 findbugs 2m 15s the patch passed
          +1 javadoc 0m 49s the patch passed
                Other Tests
          -1 unit 64m 1s hadoop-hdfs in the patch failed.
          +1 unit 3m 24s hadoop-hdfs-httpfs in the patch passed.
          +1 asflicense 0m 16s The patch does not generate ASF License warnings.
          99m 4s



          Reason Tests
          Failed junit tests hadoop.hdfs.TestDFSStripedOutputStreamWithFailure080
            hadoop.hdfs.server.namenode.ha.TestPipelinesFailover
            hadoop.hdfs.TestDFSStripedOutputStreamWithFailure090
            hadoop.hdfs.TestDFSStripedOutputStreamWithFailure070



          Subsystem Report/Notes
          Docker Image:yetus/hadoop:14b5c93
          JIRA Issue HDFS-12162
          JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12880290/HDFS-12162.01.patch
          Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle
          uname Linux 23b0df1b3451 3.13.0-119-generic #166-Ubuntu SMP Wed May 3 12:18:55 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
          Build tool maven
          Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh
          git revision trunk / 024c3ec
          Default Java 1.8.0_131
          findbugs v3.1.0-RC1
          findbugs https://builds.apache.org/job/PreCommit-HDFS-Build/20565/artifact/patchprocess/branch-findbugs-hadoop-hdfs-project_hadoop-hdfs-warnings.html
          unit https://builds.apache.org/job/PreCommit-HDFS-Build/20565/artifact/patchprocess/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
          Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/20565/testReport/
          modules C: hadoop-hdfs-project/hadoop-hdfs hadoop-hdfs-project/hadoop-hdfs-httpfs U: hadoop-hdfs-project
          Console output https://builds.apache.org/job/PreCommit-HDFS-Build/20565/console
          Powered by Apache Yetus 0.6.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 14s Docker mode activated.       Prechecks +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.       trunk Compile Tests 0 mvndep 0m 23s Maven dependency ordering for branch +1 mvninstall 13m 48s trunk passed +1 compile 1m 29s trunk passed +1 checkstyle 0m 40s trunk passed +1 mvnsite 2m 4s trunk passed -1 findbugs 1m 40s hadoop-hdfs-project/hadoop-hdfs in trunk has 9 extant Findbugs warnings. +1 javadoc 0m 55s trunk passed       Patch Compile Tests 0 mvndep 0m 7s Maven dependency ordering for patch +1 mvninstall 1m 6s the patch passed +1 compile 1m 25s the patch passed +1 javac 1m 25s the patch passed +1 checkstyle 0m 38s the patch passed +1 mvnsite 1m 59s the patch passed +1 whitespace 0m 0s The patch has no whitespace issues. +1 findbugs 2m 15s the patch passed +1 javadoc 0m 49s the patch passed       Other Tests -1 unit 64m 1s hadoop-hdfs in the patch failed. +1 unit 3m 24s hadoop-hdfs-httpfs in the patch passed. +1 asflicense 0m 16s The patch does not generate ASF License warnings. 99m 4s Reason Tests Failed junit tests hadoop.hdfs.TestDFSStripedOutputStreamWithFailure080   hadoop.hdfs.server.namenode.ha.TestPipelinesFailover   hadoop.hdfs.TestDFSStripedOutputStreamWithFailure090   hadoop.hdfs.TestDFSStripedOutputStreamWithFailure070 Subsystem Report/Notes Docker Image:yetus/hadoop:14b5c93 JIRA Issue HDFS-12162 JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12880290/HDFS-12162.01.patch Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle uname Linux 23b0df1b3451 3.13.0-119-generic #166-Ubuntu SMP Wed May 3 12:18:55 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux Build tool maven Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh git revision trunk / 024c3ec Default Java 1.8.0_131 findbugs v3.1.0-RC1 findbugs https://builds.apache.org/job/PreCommit-HDFS-Build/20565/artifact/patchprocess/branch-findbugs-hadoop-hdfs-project_hadoop-hdfs-warnings.html unit https://builds.apache.org/job/PreCommit-HDFS-Build/20565/artifact/patchprocess/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt Test Results https://builds.apache.org/job/PreCommit-HDFS-Build/20565/testReport/ modules C: hadoop-hdfs-project/hadoop-hdfs hadoop-hdfs-project/hadoop-hdfs-httpfs U: hadoop-hdfs-project Console output https://builds.apache.org/job/PreCommit-HDFS-Build/20565/console Powered by Apache Yetus 0.6.0-SNAPSHOT http://yetus.apache.org This message was automatically generated.
          Hide
          ajayydv Ajay Kumar added a comment -

          Yongjun Zhang Attaching the patch for change in WebHDFS.md (added an entry for listing file) and javadoc change in FSOperations. Please review it.

          Show
          ajayydv Ajay Kumar added a comment - Yongjun Zhang Attaching the patch for change in WebHDFS.md (added an entry for listing file) and javadoc change in FSOperations. Please review it.
          Hide
          ajayydv Ajay Kumar added a comment -

          Hi Yongjun Zhang, Are you referring to webhdfs documentation? Do you mean we should update webhdfs documentation to include an example for file path.
          Thanks!!

          Show
          ajayydv Ajay Kumar added a comment - Hi Yongjun Zhang , Are you referring to webhdfs documentation? Do you mean we should update webhdfs documentation to include an example for file path. Thanks!!

            People

            • Assignee:
              ajayydv Ajay Kumar
              Reporter:
              yzhangal Yongjun Zhang
            • Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development