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

qiang Liu commented on HBASE-23271:
-----------------------------------

 [~psomogyi] could you please review this? thanks in advance.

> HFileReader get split point handle empty HFile better
> -----------------------------------------------------
>
>                 Key: HBASE-23271
>                 URL: https://issues.apache.org/jira/browse/HBASE-23271
>             Project: HBase
>          Issue Type: Improvement
>          Components: regionserver
>    Affects Versions: 3.0.0, 1.1.7
>            Reporter: qiang Liu
>            Assignee: qiang Liu
>            Priority: Minor
>              Labels: easyfix
>         Attachments: HBASE-23271.patch
>
>
> currenttly if we call org.apache.hadoop.hbase.io.hfile.HFileReaderImpl#midKey 
> on an empty HFile, we got an exception like
>  java.io.IOException: HFile empty
> since the function return an Optional<Cell> , I think it's better return 
> Optional.empty() instead of throw An Exception
> when a region with muiltiple column family grow big enough to be splited, if 
> got some empty column family, will got some warn log like this
> java.io.IOException: HFile empty at 
> org.apache.hadoop.hbase.io.hfile.HFileBlockIndex$BlockIndexReader.midkey(HFileBlockIndex.java:334)
> sinece exception is catched,  split logic will go on and got right result



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to