You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Enis Soztutar (JIRA)" <ji...@apache.org> on 2016/11/08 02:34:58 UTC

[jira] [Commented] (HBASE-17045) Unify the implementation of small scan and regular scan

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

Enis Soztutar commented on HBASE-17045:
---------------------------------------

Thanks Duo for creating the issue. Let me copy-paste for context: 
{quote}
I understand the reason why we want to avoid 3 RPCs per scan if the scan is really small, but I think we should have made it so that ALL scans are saving RPCs, and becomes a "small" scan automatically without the client using a different API or Scan.setSmall().
There is no reason for regular scans to have openScan() and next() calls separately. We can easily make it so that Scanner open will return the next set of batch results. And we can make it so that the region server at the end of the scan when the region is exhausted automatically close the scanner before returning and give the results back to the client. So, for a "small" scan, the first RPC will open the results, and fetch all the results in the batch and return by closing the scanner in a single RPC automatically. What do you guys think? 
{quote}

> Unify the implementation of small scan and regular scan
> -------------------------------------------------------
>
>                 Key: HBASE-17045
>                 URL: https://issues.apache.org/jira/browse/HBASE-17045
>             Project: HBase
>          Issue Type: Sub-task
>          Components: Client, scan
>    Affects Versions: 2.0.0, 1.4.0
>            Reporter: Duo Zhang
>             Fix For: 2.0.0
>
>
> See [~enis]'s comment in HBASE-16838
> https://issues.apache.org/jira/browse/HBASE-16838?focusedCommentId=15637803&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-15637803
> But there is another scenario that we need small scan is that, we do not know the stop row but we only want a small set of results. For example, in the implementation of region locator, we will use small scan and set caching to 1 as we only need one row.
> So I think we need to add a new option(maybe called limit?) for the scan object, and deprecate the small option. And the server side modification should also be committed to branch-1 to simplify the logic of async client in 2.0.



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