You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by 魏超 <nn...@gmail.com> on 2012/02/10 10:13:00 UTC
CustomFilter.filterRowkey may get row which has be deleted?
I'm using *HBase-0.92.0rc4*. And there is a problem really confuse me.
I defined a CustomFilter to filter some rows, i override the method "*
filterRowkey*" to print out which rows the filter has meet.
And there is one row be deleted through JAVA client:
*htable.delete(new Delete(theRowkey))*
but when i use the CustomFilter above, I can still see this deleted-rowkey
be printed.
I try many times but the problem still alive.
*(Sometimes I shutdown and restart **HBase** the problem may be auto-sloved
(I'm not sure abount it, but it seems like that))*
Can some one give me some helps, thanks!
Re: CustomFilter.filterRowkey may get row which has be deleted?
Posted by weichao <nn...@gmail.com>.
Hello Stack, i miss your mail days before.
Yes I don't see the delete or the puts it overshadows/deletes but in the
Filters.
So how can I filter blocks delete type cells in filter's method such as
"filterRowkey"? Is there any API to detect a cell is DELETE type?
I'm newer to HBase, Thanks for your help~
2012/2/11 Stack <st...@duboce.net>
> On Fri, Feb 10, 2012 at 1:13 AM, 魏超 <nn...@gmail.com> wrote:
> > I'm using *HBase-0.92.0rc4*. And there is a problem really confuse me.
> > I defined a CustomFilter to filter some rows, i override the method "*
> > filterRowkey*" to print out which rows the filter has meet.
> >
> > And there is one row be deleted through JAVA client:
> > *htable.delete(new Delete(theRowkey))*
> >
> > but when i use the CustomFilter above, I can still see this
> deleted-rowkey
> > be printed.
> > I try many times but the problem still alive.
> >
>
> You expect the delete to not show in the output?
>
> Delete is a cell like any other. Unless your filter blocks delete
> type cells, I am not surprised its output.
>
> Client-side, you don't see the delete or the puts it overshadows/deletes,
> right?
>
> St.Ack
>
Re: CustomFilter.filterRowkey may get row which has be deleted?
Posted by weichao <nn...@gmail.com>.
Thanks, i think it really strange too.
Is there some kind of Cache to Filters? For restart the problem may be
sloved, but not every time.
I'll recheck my code later to see if I made anything wrong. If simple code
keeping exist this problem, i will post anthor mail to ask Help.
Thank you Stack and lars
2012/2/11 lars hofhansl <lh...@yahoo.com>
> I think it would at least be inconsistent with how we handle
> Filter.filterKeyValue(KeyValue), which is done in ScanQueryMatcher after
> deleted cells are skipped.
>
> From looking at the RegionScannerImpl.nextInternal code it seems
> filterRowKey(byte[]) should not see deleted row keys either, as it should
> only see rows whose cells went through ScanQueryMatcher before.
> Strange...
>
>
>
> ________________________________
> From: Stack <st...@duboce.net>
> To: user@hbase.apache.org
> Sent: Friday, February 10, 2012 8:51 AM
> Subject: Re: CustomFilter.filterRowkey may get row which has be deleted?
>
> On Fri, Feb 10, 2012 at 1:13 AM, 魏超 <nn...@gmail.com> wrote:
> > I'm using *HBase-0.92.0rc4*. And there is a problem really confuse me.
> > I defined a CustomFilter to filter some rows, i override the method "*
> > filterRowkey*" to print out which rows the filter has meet.
> >
> > And there is one row be deleted through JAVA client:
> > *htable.delete(new Delete(theRowkey))*
> >
> > but when i use the CustomFilter above, I can still see this
> deleted-rowkey
> > be printed.
> > I try many times but the problem still alive.
> >
>
> You expect the delete to not show in the output?
>
> Delete is a cell like any other. Unless your filter blocks delete
> type cells, I am not surprised its output.
>
> Client-side, you don't see the delete or the puts it overshadows/deletes,
> right?
>
> St.Ack
>
Re: CustomFilter.filterRowkey may get row which has be deleted?
Posted by lars hofhansl <lh...@yahoo.com>.
I think it would at least be inconsistent with how we handle Filter.filterKeyValue(KeyValue), which is done in ScanQueryMatcher after deleted cells are skipped.
From looking at the RegionScannerImpl.nextInternal code it seems filterRowKey(byte[]) should not see deleted row keys either, as it should only see rows whose cells went through ScanQueryMatcher before.
Strange...
________________________________
From: Stack <st...@duboce.net>
To: user@hbase.apache.org
Sent: Friday, February 10, 2012 8:51 AM
Subject: Re: CustomFilter.filterRowkey may get row which has be deleted?
On Fri, Feb 10, 2012 at 1:13 AM, 魏超 <nn...@gmail.com> wrote:
> I'm using *HBase-0.92.0rc4*. And there is a problem really confuse me.
> I defined a CustomFilter to filter some rows, i override the method "*
> filterRowkey*" to print out which rows the filter has meet.
>
> And there is one row be deleted through JAVA client:
> *htable.delete(new Delete(theRowkey))*
>
> but when i use the CustomFilter above, I can still see this deleted-rowkey
> be printed.
> I try many times but the problem still alive.
>
You expect the delete to not show in the output?
Delete is a cell like any other. Unless your filter blocks delete
type cells, I am not surprised its output.
Client-side, you don't see the delete or the puts it overshadows/deletes, right?
St.Ack
Re: CustomFilter.filterRowkey may get row which has be deleted?
Posted by Stack <st...@duboce.net>.
On Fri, Feb 10, 2012 at 1:13 AM, 魏超 <nn...@gmail.com> wrote:
> I'm using *HBase-0.92.0rc4*. And there is a problem really confuse me.
> I defined a CustomFilter to filter some rows, i override the method "*
> filterRowkey*" to print out which rows the filter has meet.
>
> And there is one row be deleted through JAVA client:
> *htable.delete(new Delete(theRowkey))*
>
> but when i use the CustomFilter above, I can still see this deleted-rowkey
> be printed.
> I try many times but the problem still alive.
>
You expect the delete to not show in the output?
Delete is a cell like any other. Unless your filter blocks delete
type cells, I am not surprised its output.
Client-side, you don't see the delete or the puts it overshadows/deletes, right?
St.Ack