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 "Hairong Kuang (JIRA)" <ji...@apache.org> on 2008/02/15 19:16:07 UTC
[jira] Created: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
NameNode should throw FileNotFoundException for nonexistent files
-----------------------------------------------------------------
Key: HADOOP-2842
URL: https://issues.apache.org/jira/browse/HADOOP-2842
Project: Hadoop Core
Issue Type: Improvement
Components: dfs
Affects Versions: 0.16.0
Reporter: Hairong Kuang
Fix For: 0.17.0
Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588955#action_12588955 ]
Edward J. Yoon commented on HADOOP-2842:
----------------------------------------
Oh, thank you lohit.
Then should we close this issue?
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch, 2842_v02.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Edward J. Yoon updated HADOOP-2842:
-----------------------------------
Attachment: 2842_v02.patch
Thank you for your review. I fixed them.
1. When file not found, FSNamesystem.exist() will throws FileNotFoundException.
2. A unnecessary test was removed.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch, 2842_v02.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Edward J. Yoon updated HADOOP-2842:
-----------------------------------
Attachment: 2842_v01.patch
Please review this v01.patch.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Edward J. Yoon updated HADOOP-2842:
-----------------------------------
Resolution: Duplicate
Status: Resolved (was: Patch Available)
Yes, actually, This issue will be fixed by HADOOP-3239 and HADOOP-3160.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch, 2842_v02.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Edward J. Yoon updated HADOOP-2842:
-----------------------------------
Fix Version/s: 0.18.0
Status: Patch Available (was: Open)
Submitting.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "lohit vijayarenu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588964#action_12588964 ]
lohit vijayarenu commented on HADOOP-2842:
------------------------------------------
I am assuming this JIRA was for getFileInfo, if so, yes we could close this.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch, 2842_v02.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Hairong Kuang (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588679#action_12588679 ]
Hairong Kuang commented on HADOOP-2842:
---------------------------------------
The problem described in this issue was fixed as part of HADOOP-2841. This patch fixed the javadoc. Thanks Edward. Here are a few comments:
1. Although FSNamesystem.exists deprecated, could you please fix it so it returns true only when getFileInfo throws a FileNotFoundException?
2. In TestDFSMkdirs, the mini dfs cluster is brought up with the format flag true. So the check of the non-existent directory is unnecessary.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Robert Chansler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Robert Chansler updated HADOOP-2842:
------------------------------------
Fix Version/s: (was: 0.17.0)
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "lohit vijayarenu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588951#action_12588951 ]
lohit vijayarenu commented on HADOOP-2842:
------------------------------------------
Hi Edward,
The patch looks good. But the issue address by this patch has changed in 2 ways.
- getFileInfo() no longer throws FileNotFoundException it returns null if file not found, HADOOP-3239. So we might not need this here.
- exits() would be removed from server side HADOOP-3160
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch, 2842_v02.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "Edward J. Yoon (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Edward J. Yoon reassigned HADOOP-2842:
--------------------------------------
Assignee: Edward J. Yoon
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HADOOP-2842) NameNode should throw
FileNotFoundException for nonexistent files
Posted by "lohit vijayarenu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HADOOP-2842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12588720#action_12588720 ]
lohit vijayarenu commented on HADOOP-2842:
------------------------------------------
bq. 1. Although FSNamesystem.exists deprecated, could you please fix it so it returns true only when getFileInfo throws a FileNotFoundException?
HADOOP-3239 would change getFileInfo to return null if file not found instead of throwing FileNotFoundException. Since this is for 0.18 it would be worth waiting for HADOOP-3239 and then updating your patch.
> NameNode should throw FileNotFoundException for nonexistent files
> -----------------------------------------------------------------
>
> Key: HADOOP-2842
> URL: https://issues.apache.org/jira/browse/HADOOP-2842
> Project: Hadoop Core
> Issue Type: Improvement
> Components: dfs
> Affects Versions: 0.16.0
> Reporter: Hairong Kuang
> Assignee: Edward J. Yoon
> Fix For: 0.18.0
>
> Attachments: 2842_v01.patch
>
>
> Currently namenode throws an IOException with a "File does not exist" message for nonexistent files. It would be better to throw FileNotFound exception. So the client does not need to parse the error message to find out the real cause of the I/O error.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.