hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yerui Sun (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-14497) Reverse Scan threw StackOverflow caused by readPt checking
Date Tue, 29 Sep 2015 08:02:05 GMT

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

Yerui Sun commented on HBASE-14497:
-----------------------------------

I think testEnableTableWithNoRegionServers is not a stable test. 

I ran it several times on branch-1 with git commit 642273bc2a5a415eba6f1592a439a6b2b53a70a9,
without this patch. It failed in most times, but indeed succeeded in few times. I settle breakpoints
on the entry of seekToPreviousRow of MemstoreScanner&StoreFileScanner, and found that
only two calling to seekToPreviousRow for hbase:namespace, one calling return true and another
return false, neither called recursively.

 I also ran it with this patch, and got the same result. Most of times the test failed, and
succeeded in few times.

 I think there’s another problem in the test, and not related to my patch.

> Reverse Scan threw StackOverflow caused by readPt checking
> ----------------------------------------------------------
>
>                 Key: HBASE-14497
>                 URL: https://issues.apache.org/jira/browse/HBASE-14497
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 2.0.0, 0.98.14, 1.3.0
>            Reporter: Yerui Sun
>         Attachments: HBASE-14497-0.98.patch, HBASE-14497-branch-1-v2.patch, HBASE-14497-branch-1.patch,
HBASE-14497-master-v2.patch, HBASE-14497-master-v3.patch, HBASE-14497-master-v3.patch, HBASE-14497-master-v4.patch,
HBASE-14497-master.patch
>
>
> I met stack overflow error in StoreFileScanner.seekToPreviousRow using reversed scan.
I searched and founded HBASE-14155, but it seems to be a different reason.
> The seekToPreviousRow will fetch the row which closest before, and compare mvcc to the
readPt, which acquired when scanner created. If the row's mvcc is bigger than readPt, an recursive
call of seekToPreviousRow will invoked, to find the next closest before row.
> Considering we created a scanner for reversed scan, and some data with smaller rows was
written and flushed, before calling scanner next. When seekToPreviousRow was invoked, it would
call itself recursively, until all rows which written after scanner created were iterated.
The depth of recursive calling stack depends on the count of rows, the stack overflow error
will be threw if the count of rows is large, like 10000.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message