Re: FileSystem contract of listStatus

2011-11-07 Thread Alejandro Abdelnur
tus is for pattern matching and listStatus is for listing all the > files in given directory. > >> >> >> >> > >> > Regards, >> > Uma >> > - Original Message - >> > From: Harsh J >> > Date: Thursday, November 3, 2011

Re: FileSystem contract of listStatus

2011-11-05 Thread Uma Maheswara Rao G 72686
- Original Message - From: "M. C. Srivas" Date: Sunday, November 6, 2011 3:13 am Subject: Re: FileSystem contract of listStatus To: common-dev@hadoop.apache.org > On Thu, Nov 3, 2011 at 4:27 AM, Uma Maheswara Rao G 72686 < > mahesw...@huawei.com> wrote: > >

Re: FileSystem contract of listStatus

2011-11-05 Thread M. C. Srivas
ly. That's why we have globStatus() and listStatus() ... those who want a sorted list can use globStatus(). > > Regards, > Uma > - Original Message - > From: Harsh J > Date: Thursday, November 3, 2011 7:52 am > Subject: Re: FileSystem contract of listStatus >

Re: FileSystem contract of listStatus

2011-11-03 Thread Uma Maheswara Rao G 72686
Yes, i remember this issue filed by Harsh recently. GlobStatus will sort the results and return. May be we can fix for listStatus in the same way. Regards, Uma - Original Message - From: Harsh J Date: Thursday, November 3, 2011 7:52 am Subject: Re: FileSystem contract of listStatus

Re: FileSystem contract of listStatus

2011-11-02 Thread Harsh J
Perhaps fixes against this can be covered as part of https://issues.apache.org/jira/browse/HADOOP-7659 On 03-Nov-2011, at 5:44 AM, Ted Dunning wrote: > I think that the API docs actually say globStatus is ordered and leave the > ordering semantics for listStatus undefined. > > http://hadoop.apa

Re: FileSystem contract of listStatus

2011-11-02 Thread Ted Dunning
I think that the API docs actually say globStatus is ordered and leave the ordering semantics for listStatus undefined. http://hadoop.apache.org/common/docs/r0.20.2/api/org/apache/hadoop/fs/FileSystem.html#globStatus(org.apache.hadoop.fs.Path) http://hadoop.apache.org/common/docs/r0.20.2/api/org/

Re: FileSystem contract of listStatus

2011-11-02 Thread Noah Watkins
- Original Message - > From: "Eli Collins" > > RawLocalFileSystem uses Java's File#list which has "no guarantee that > the name strings in the resulting array will appear in any specific > order; they are not, in particular, guaranteed to appear in > alphabetical order.", however the FSCon

Re: FileSystem contract of listStatus

2011-11-02 Thread Eli Collins
Hey Noah, HDFS returns items in lexographic order by byte (see INode#compareBytes) but I don't think ordering was intended to be an explicit part of the contract. Ie the test probably just needs to be modified to ignore the order. RawLocalFileSystem uses Java's File#list which has "no guarantee t

FileSystem contract of listStatus

2011-11-02 Thread Noah Watkins
I have a question about the FileSystem contract in 0.20. In FileSystemContractBaseBaseTest:testFileStatus() there are several files created, and afterwards the test confirms that they are present. Here is the relevant code: FileStatus[] paths = fs.listStatus(path("/test")); paths = fs.li