Return-Path: X-Original-To: apmail-hbase-issues-archive@www.apache.org Delivered-To: apmail-hbase-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0FC0010FDC for ; Mon, 10 Feb 2014 05:19:27 +0000 (UTC) Received: (qmail 81014 invoked by uid 500); 10 Feb 2014 05:19:26 -0000 Delivered-To: apmail-hbase-issues-archive@hbase.apache.org Received: (qmail 80725 invoked by uid 500); 10 Feb 2014 05:19:25 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 80710 invoked by uid 99); 10 Feb 2014 05:19:23 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 10 Feb 2014 05:19:23 +0000 Date: Mon, 10 Feb 2014 05:19:23 +0000 (UTC) From: "ramkrishna.s.vasudevan (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HBASE-10485) PrefixFilter#filterKeyValue() should perform filtering on row key MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HBASE-10485?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13896221#comment-13896221 ] ramkrishna.s.vasudevan commented on HBASE-10485: ------------------------------------------------ Is it need to be fixed in the Prefixfilter. This fix would mean that for every KV we would evaluate the row part of it. Ideally prefixfilters are for acting on the entire row (and not on KV). What I would think is the filter AlwaysNextColFilter should say filterRow() as true? The filter's idea is not to include any KV and tries to do next_col. Then finally saying filterRow() as false would mean that though i filtered out, i need that row. Our FilterBase gives a default impl but still it makes sense to make filterRow() as true rather than fixing it in Prefixfilter. Thoughts? > PrefixFilter#filterKeyValue() should perform filtering on row key > ----------------------------------------------------------------- > > Key: HBASE-10485 > URL: https://issues.apache.org/jira/browse/HBASE-10485 > Project: HBase > Issue Type: Bug > Reporter: Ted Yu > Assignee: Ted Yu > Fix For: 0.98.0, 0.99.0 > > Attachments: 10485-0.94.txt, 10485-v1.txt > > > Niels reported an issue under the thread 'Trouble writing custom filter for use in FilterList' where his custom filter used in FilterList along with PrefixFilter produced an unexpected results. > His test can be found here: > https://github.com/nielsbasjes/HBase-filter-problem > This is due to PrefixFilter#filterKeyValue() using FilterBase#filterKeyValue() which returns ReturnCode.INCLUDE > When FilterList.Operator.MUST_PASS_ONE is specified, FilterList#filterKeyValue() would return ReturnCode.INCLUDE even when row key prefix doesn't match meanwhile the other filter's filterKeyValue() returns ReturnCode.NEXT_COL -- This message was sent by Atlassian JIRA (v6.1.5#6160)