You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by Lucian Iordache <lu...@gmail.com> on 2012/09/20 16:53:30 UTC
BitComparator bug in HBase 0.94.1 - ArrayIndexOutOfBoundsException
Hello,
I found a bug in BitComparator implementation from HBase 0.94.1.
The problem is that in the compareTo method, the value from the
BitComparator is compared against the whole buffer of a KeyValue from hbase
and the loop that compares them uses the length of the KeyValue buffer
instead of using the length of the value from the BitComparator object.
Because the length of the KeyValue buffer is bigger than the length of the
value from the BitComparator object, an ArrayIndexOutOfBoundsException
appears.
I've opened a bug for it: https://issues.apache.org/jira/browse/HBASE-6846
Maybe it helps other people that will encounter the problem.
--
Regards,
Lucian
Re: BitComparator bug in HBase 0.94.1 - ArrayIndexOutOfBoundsException
Posted by Lucian Iordache <lu...@gmail.com>.
Yes, I will do that in the next days.
On Thu, Sep 20, 2012 at 5:56 PM, Ted Yu <yu...@gmail.com> wrote:
> Thanks for reporting, Lucian.
>
> Can you attach a patch in that JIRA ?
>
> On Thu, Sep 20, 2012 at 7:53 AM, Lucian Iordache <
> lucian.george.iordache@gmail.com> wrote:
>
> > Hello,
> >
> > I found a bug in BitComparator implementation from HBase 0.94.1.
> > The problem is that in the compareTo method, the value from the
> > BitComparator is compared against the whole buffer of a KeyValue from
> hbase
> > and the loop that compares them uses the length of the KeyValue buffer
> > instead of using the length of the value from the BitComparator object.
> > Because the length of the KeyValue buffer is bigger than the length of
> the
> > value from the BitComparator object, an ArrayIndexOutOfBoundsException
> > appears.
> >
> > I've opened a bug for it:
> https://issues.apache.org/jira/browse/HBASE-6846
> >
> > Maybe it helps other people that will encounter the problem.
> >
> > --
> > Regards,
> > Lucian
> >
>
--
Numai bine,
Lucian
Re: BitComparator bug in HBase 0.94.1 - ArrayIndexOutOfBoundsException
Posted by Ted Yu <yu...@gmail.com>.
Thanks for reporting, Lucian.
Can you attach a patch in that JIRA ?
On Thu, Sep 20, 2012 at 7:53 AM, Lucian Iordache <
lucian.george.iordache@gmail.com> wrote:
> Hello,
>
> I found a bug in BitComparator implementation from HBase 0.94.1.
> The problem is that in the compareTo method, the value from the
> BitComparator is compared against the whole buffer of a KeyValue from hbase
> and the loop that compares them uses the length of the KeyValue buffer
> instead of using the length of the value from the BitComparator object.
> Because the length of the KeyValue buffer is bigger than the length of the
> value from the BitComparator object, an ArrayIndexOutOfBoundsException
> appears.
>
> I've opened a bug for it: https://issues.apache.org/jira/browse/HBASE-6846
>
> Maybe it helps other people that will encounter the problem.
>
> --
> Regards,
> Lucian
>