hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-4754) FSTableDescriptors.getTableInfoPath() should handle FileNotFoundException
Date Tue, 08 Nov 2011 01:24:51 GMT

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

Hudson commented on HBASE-4754:
-------------------------------

Integrated in HBase-TRUNK #2419 (See [https://builds.apache.org/job/HBase-TRUNK/2419/])
    HBASE-4754  FSTableDescriptors.getTableInfoPath() should handle FileNotFoundException

tedyu : 
Files : 
* /hbase/trunk/CHANGES.txt
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/LogCleaner.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/MasterFileSystem.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/SplitLogManager.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/StoreFile.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/wal/HLog.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/util/FSTableDescriptors.java
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/util/FSUtils.java

                
> FSTableDescriptors.getTableInfoPath() should handle FileNotFoundException
> -------------------------------------------------------------------------
>
>                 Key: HBASE-4754
>                 URL: https://issues.apache.org/jira/browse/HBASE-4754
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 0.92.0
>            Reporter: Ted Yu
>            Assignee: Ted Yu
>            Priority: Blocker
>             Fix For: 0.92.0
>
>         Attachments: 4754-0.92.txt, 4754-v2.txt, 4754.txt
>
>
> As reported by Roman in the thread entitled 'HBase 0.92/Hadoop 0.22 test results', table
creation would result in the following if hadoop 0.22 is the underlying platform:
> {code}
> 11/11/05 19:08:48 INFO handler.CreateTableHandler: Attemping to create
> the table b
> 11/11/05 19:08:48 ERROR handler.CreateTableHandler: Error trying to
> create the table b
> java.io.FileNotFoundException: File
> hdfs://ip-10-110-254-200.ec2.internal:17020/hbase/b does not exist.
>        at org.apache.hadoop.hdfs.DistributedFileSystem.listStatus(DistributedFileSystem.java:387)
>        at org.apache.hadoop.fs.FileSystem.listStatus(FileSystem.java:1085)
>        at org.apache.hadoop.fs.FileSystem.listStatus(FileSystem.java:1110)
>        at org.apache.hadoop.hbase.util.FSTableDescriptors.getTableInfoPath(FSTableDescriptors.java:257)
>        at org.apache.hadoop.hbase.util.FSTableDescriptors.getTableInfoPath(FSTableDescriptors.java:243)
>        at org.apache.hadoop.hbase.util.FSTableDescriptors.createTableDescriptor(FSTableDescriptors.java:566)
>        at org.apache.hadoop.hbase.util.FSTableDescriptors.createTableDescriptor(FSTableDescriptors.java:535)
>        at org.apache.hadoop.hbase.util.FSTableDescriptors.createTableDescriptor(FSTableDescriptors.java:519)
>        at org.apache.hadoop.hbase.master.handler.CreateTableHandler.handleCreateTable(CreateTableHandler.java:140)
>        at org.apache.hadoop.hbase.master.handler.CreateTableHandler.process(CreateTableHandler.java:126)
>        at org.apache.hadoop.hbase.executor.EventHandler.run(EventHandler.java:168)
>        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>        at java.lang.Thread.run(Thread.java:619)
> {code}
> This was due to how DistributedFileSystem.listStatus() in 0.22 handles non-existent directory:
> {code}
>   @Override
>   public FileStatus[] listStatus(Path p) throws IOException {
>     String src = getPathName(p);
>     // fetch the first batch of entries in the directory
>     DirectoryListing thisListing = dfs.listPaths(
>         src, HdfsFileStatus.EMPTY_NAME);
>     if (thisListing == null) { // the directory does not exist
>       throw new FileNotFoundException("File " + p + " does not exist.");
>     }
> {code}
> So in FSTableDescriptors.getTableInfoPath(), we should catch FileNotFoundException and
treat it the same way as status being null.

--
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

        

Mime
View raw message