You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by "Bryan Duxbury (JIRA)" <ji...@apache.org> on 2007/10/24 19:52:51 UTC

[jira] Created: (HADOOP-2097) DistributedFileSystem.listPaths with some paths causes directory to be cleared

DistributedFileSystem.listPaths with some paths causes directory to be cleared
------------------------------------------------------------------------------

                 Key: HADOOP-2097
                 URL: https://issues.apache.org/jira/browse/HADOOP-2097
             Project: Hadoop
          Issue Type: Bug
          Components: dfs
    Affects Versions: 0.14.2
         Environment: Linux
            Reporter: Bryan Duxbury


I am currently writing a Ruby wrapper to the Java DFS client libraries via JNI. While attempting to test the listPaths method of the FileSystem class, I discovered that passing a Path URI like "hdfs://tf11:7276/user/rapleaf" results in the /user/rapleaf directory being cleared of all contents. A path URI like "hdfs://tf11:7276/user/rapleaf/*" will list the contents of the directory without damage. 

I have verified this by creating directories and listing via the bin/hadoop dfs -ls command. 

Obviously passing an incorrectly formatted string a method that should be read-only should not have destructive effects. Also, the actual required path syntax for listings should be recorded in the documentation.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HADOOP-2097) DistributedFileSystem.listPaths with some paths causes directory to be cleared

Posted by "Chris Douglas (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-2097?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12537412 ] 

Chris Douglas commented on HADOOP-2097:
---------------------------------------

1) listPaths is deprecated; consider listStatus
2) I'm having trouble reproducing this. Can you provide some code or more explicit instructions?

> DistributedFileSystem.listPaths with some paths causes directory to be cleared
> ------------------------------------------------------------------------------
>
>                 Key: HADOOP-2097
>                 URL: https://issues.apache.org/jira/browse/HADOOP-2097
>             Project: Hadoop
>          Issue Type: Bug
>          Components: dfs
>    Affects Versions: 0.14.2
>         Environment: Linux
>            Reporter: Bryan Duxbury
>
> I am currently writing a Ruby wrapper to the Java DFS client libraries via JNI. While attempting to test the listPaths method of the FileSystem class, I discovered that passing a Path URI like "hdfs://tf11:7276/user/rapleaf" results in the /user/rapleaf directory being cleared of all contents. A path URI like "hdfs://tf11:7276/user/rapleaf/*" will list the contents of the directory without damage. 
> I have verified this by creating directories and listing via the bin/hadoop dfs -ls command. 
> Obviously passing an incorrectly formatted string a method that should be read-only should not have destructive effects. Also, the actual required path syntax for listings should be recorded in the documentation.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.