[ 
https://issues.apache.org/jira/browse/HADOOP-8709?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439546#comment-13439546
 ] 

Robert Joseph Evans commented on HADOOP-8709:
---------------------------------------------

The thing that bugs me is that the documentation and the behavior do not match. 
It especially bugs me because it is on something that is marked public stable 
and is commonly used.  If I had my wish the behavior would match that of 1.0, 
just because the exception may not be exceptional, but is somewhat rare.  I 
fear it will catch users off guard when it does show up, and their code will 
not be able to handle it.  Additionally most globbing libraries I have seen 
never throw an exception or return an error, most globbing is in c, unless 
something is seriously wrong.

However, a lot of this is selfishness on my part because most of my users are 
on the 1.0 line, and would expect that behavior.  I realize that making another 
change to the APIs behavior is risky so I am fine with whatever we do so long 
as the documentation and the API's behavior match.

Now putting on my release manager hat I really would like to do a release of 
0.23.3 soon, but this is one JIRA that I consider somewhat of a blocker because 
of the mismatch.  However we fix it I would like a fix soon.

I am a +1 on the patch as is. I reviewed it and the code looks fine to me. but 
Jakob, I am not going to check it in right away.  If you don't want this to 
happen feel free to give it a -1 or even a -0, and I will look into posting a 
patch that updates the documentation instead.  
                
> globStatus changed behavior from 0.20/1.x
> -----------------------------------------
>
>                 Key: HADOOP-8709
>                 URL: https://issues.apache.org/jira/browse/HADOOP-8709
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.23.0, 2.0.0-alpha
>            Reporter: Jason Lowe
>            Assignee: Jason Lowe
>            Priority: Critical
>         Attachments: HADOOP-8709.patch, HADOOP-8709.patch
>
>
> In 0.20 or 1.x, globStatus will return an empty array if the glob pattern 
> does not match any files.  After HADOOP-6201 it throws FileNotFoundException. 
>  The javadoc states it will return an empty array.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to