[
https://issues.apache.org/jira/browse/HBASE-15378?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15175531#comment-15175531
]
Phil Yang commented on HBASE-15378:
-----------------------------------
https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java#L2739-L2768
Line 2757 is a break so we won't reach L2764, so the response won't have
hasMoreResults flag. And I don't think we have correct handling when
hasMoreResults is true because:
{code}
if (null != values && values.length > 0 &&
callable.hasMoreResultsContext()) {
serverHasMoreResults = callable.getServerHasMoreResults() &&
partialResults.isEmpty();
}
} while ((doneWithRegion(remainingResultSize, countdown,
serverHasMoreResults)
&& (!partialResults.isEmpty() || possiblyNextScanner(countdown, values
== null))));
{code}
if result.length==0 serverHasMoreResults will be still false, so doneWithRegion
will return true and partialResults is empty(we read nothing) so we will go to
read next region.
> Scanner can not handle a heartbeat message with no results
> ----------------------------------------------------------
>
> Key: HBASE-15378
> URL: https://issues.apache.org/jira/browse/HBASE-15378
> Project: HBase
> Issue Type: Bug
> Affects Versions: 1.2.0, 1.1.3
> Reporter: Phil Yang
> Assignee: Phil Yang
> Priority: Critical
> Attachments: HBASE-15378-v1.txt, HBASE-15378-v2.txt
>
>
> When a RS scanner get a TIME_LIMIT_REACHED_MID_ROW state, they will stop
> scanning and send back what it has read to client and mark the message as a
> heartbeat message. If there is no cell has been read, it will be an empty
> response.
> However, ClientScanner only handles the situation that the client gets an
> empty heartbeat and its cache is not empty. If the cache is empty too, it
> will be regarded as end-of-region and open a new scanner for next region.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)