hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zheng Hu (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-18066) Get with closest_row_before on "hbase:meta" can return empty Cell during region merge/split
Date Tue, 23 May 2017 02:41:04 GMT

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

Zheng Hu commented on HBASE-18066:
----------------------------------

bq.  My question is why we implement the function with two steps? I mean first get the row
key and then use this row key to get the row. Is it only an implementation compromise? Or
intentional?

[~Apache9],  If implement the function with one step(scan backward) ,  then the implementation
would be similar to reverse scan which was not implemented yet (Maybe a lot of  work was needed
for reverse scan at that time),  so we provided the method getClosestRowBefore to locate the
region in hbase:meta, I guess. 

For compatibility, we should keep getClosestRowBefore in branch-1.x  & master branch at
server side, so we should fix the bug at server side. 

There are two way to fix the bug, In my opinion: 
1.    Just implement getClosestRowBefore by reverse scan at server side. 
2.    Still two steps,  but we get the readpoint firstly, and then pass the readpoint in both
getting rowkey step and getting row step.  

Let me have a try. 

> Get with closest_row_before on "hbase:meta" can return empty Cell during region merge/split
> -------------------------------------------------------------------------------------------
>
>                 Key: HBASE-18066
>                 URL: https://issues.apache.org/jira/browse/HBASE-18066
>             Project: HBase
>          Issue Type: Bug
>          Components: hbase, regionserver
>    Affects Versions: 1.3.1
>         Environment: Linux (16.04.2), MacOS 10.11.6.
> Standalone and distributed HBase setup.
>            Reporter: Andrey Elenskiy
>         Attachments: TestGetWithClosestRowBeforeWhenSplit.java
>
>
> During region split/merge there's a brief period of time where doing a "Get" with "closest_row_before=true"
on "hbase:meta" may return empty "GetResponse.result.cell" field even though parent, splitA
and splitB regions are all in "hbase:meta". Both gohbase (https://github.com/tsuna/gohbase)
and AsyncHBase (https://github.com/OpenTSDB/asynchbase) interprets this as "TableDoesNotExist",
which is returned to the client.
> Here's a gist that reproduces this problem: https://gist.github.com/Timoha/c7a236b768be9220e85e53e1ca53bf96.
Note that you have to use older HTable client (I used 1.2.4) as current versions ignore `Get.setClosestRowBefore(bool)`
option.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message