[
https://issues.apache.org/jira/browse/HBASE-22448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16846406#comment-16846406
]
Zheng Hu commented on HBASE-22448:
----------------------------------
For a cell , we either have a comparision with the preivous next hint , or pass
it to subFilter have a comparison in filterCell. Usually, the comparison in
filterCell is more efficient because we know what's the excatly bytes need to
compare inside the sub-filter implementation while can only compare the whole
key part in the high-level FilterListWithOR.
If all sub-filters SEEK_NEXT_HINT implementation are idempotent, which means
passing the same cell into filterCell and won't impact its internal state, we
may optimize the SEEK_NEXT_HINT logic as passing a cell into
subFilter#filterCell ( Never have a comparision with the previous next hint
cell ). But what I am concerning is that NOT every sub-filters SEEK_NEXT_HINT
implementation can keep it as idempotent. Even if they're now, it's easy to be
broken by some future bug fix or improvement.
So I tend to keep the current implementation in branch-1.4, Thanks.
> Scan is slow for Multiple Column prefixes
> -----------------------------------------
>
> Key: HBASE-22448
> URL: https://issues.apache.org/jira/browse/HBASE-22448
> Project: HBase
> Issue Type: Bug
> Components: Scanners
> Affects Versions: 1.4.8, 1.4.9
> Reporter: Karthick
> Assignee: Zheng Hu
> Priority: Critical
> Labels: prefix, scan, scanner
> Fix For: 1.5.0, 1.4.10
>
> Attachments: 0001-benchmark-UT.patch, HBaseFileImport.java,
> filter-list-with-or-internal-2.png,
> org.apache.hadoop.hbase.filter.TestSlowColumnPrefix-output.zip,
> qualifiers.txt, scanquery.txt
>
>
> While scanning a row (around 10 lakhs columns) with 100 column prefixes, it
> takes around 4 seconds in hbase-1.2.5 and when the same query is executed in
> hbase-1.4.9 it takes around 50 seconds.
> Is there any way to optimise this?
>
> *P.S:*
> We have applied the patch provided in
> [-HBASE-21620-|https://jira.apache.org/jira/browse/HBASE-21620] and
> [-HBASE-21734-|https://jira.apache.org/jira/browse/HBASE-21734] . Attached
> *qualifiers*.*txt* file which contains the column keys. Use the
> *HBaseFileImport.java* file provided to populate in your table and use
> *scanquery.txt* to query.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)