You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hbase.apache.org by Lars George <la...@gmail.com> on 2009/12/31 11:05:12 UTC

Re: svn commit: r894799 - in /hadoop/hbase/branches/0.20: CHANGES.txt src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java

Hi Andy,

Did this fix http://www.mail-archive.com/hbase-user@hadoop.apache.org/msg07734.html
? I missed the issue and had not yet time to test this (as 0.20 does
not have the junit 4 test). If so, does Sandy know already I assume?

Thanks,
Lars

On Thu, Dec 31, 2009 at 10:20 AM,  <ap...@apache.org> wrote:
> Author: apurtell
> Date: Thu Dec 31 09:20:18 2009
> New Revision: 894799
>
> URL: http://svn.apache.org/viewvc?rev=894799&view=rev
> Log:
> HBASE-2082 TableInputFormat is ignoring input scan's stop row setting
>
> Modified:
>    hadoop/hbase/branches/0.20/CHANGES.txt
>    hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java
>
> Modified: hadoop/hbase/branches/0.20/CHANGES.txt
> URL: http://svn.apache.org/viewvc/hadoop/hbase/branches/0.20/CHANGES.txt?rev=894799&r1=894798&r2=894799&view=diff
> ==============================================================================
> --- hadoop/hbase/branches/0.20/CHANGES.txt (original)
> +++ hadoop/hbase/branches/0.20/CHANGES.txt Thu Dec 31 09:20:18 2009
> @@ -34,6 +34,8 @@
>                an immediate region server shutdown (Sam Pullara via JD)
>    HBASE-2078  Add JMX settings as commented out lines to hbase-env.sh
>                (Lars George via JD)
> +   HBASE-2082  TableInputFormat is ignoring input scan's stop row setting
> +               (Scott Wang via Andrew Purtell)
>
>   IMPROVEMENTS
>    HBASE-1961  HBase EC2 scripts
>
> Modified: hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java
> URL: http://svn.apache.org/viewvc/hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java?rev=894799&r1=894798&r2=894799&view=diff
> ==============================================================================
> --- hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java (original)
> +++ hadoop/hbase/branches/0.20/src/java/org/apache/hadoop/hbase/mapreduce/TableInputFormatBase.java Thu Dec 31 09:20:18 2009
> @@ -298,8 +298,9 @@
>         byte[] splitStart = startRow.length == 0 ||
>           Bytes.compareTo(keys.getFirst()[i], startRow) >= 0 ?
>             keys.getFirst()[i] : startRow;
> -        byte[] splitStop = stopRow.length == 0 ||
> -          Bytes.compareTo(keys.getSecond()[i], stopRow) <= 0 ?
> +        byte[] splitStop = (stopRow.length == 0 ||
> +          Bytes.compareTo(keys.getSecond()[i], stopRow) <= 0) &&
> +          keys.getSecond()[i].length > 0 ?
>             keys.getSecond()[i] : stopRow;
>         InputSplit split = new TableSplit(table.getTableName(),
>           splitStart, splitStop, regionLocation);
>
>
>

Re: svn commit: r894799 - in /hadoop/hbase/branches/0.20

Posted by Lars George <la...@gmail.com>.
Hi Andy,

We have a test in trunk. I will see if I fund time to check it way it  
did not find that edge case.

Lars

On Dec 31, 2009, at 21:57, Andrew Purtell <ap...@apache.org> wrote:

> Hey Lars,
>
> The patch fixes the bug as described, on visual inspection. I made  
> sure no mapreduce package tests broke before commit but did not  
> write a unit test for it. We could use one.
>
>  - Andy
>
>
>
> ----- Original Message ----
>> From: Lars George <la...@gmail.com>
>> To: hbase-dev@hadoop.apache.org
>> Cc: apurtell <ap...@apache.org>
>> Sent: Thu, December 31, 2009 2:05:12 AM
>> Subject: Re: svn commit: r894799 - in /hadoop/hbase/branches/0.20
>>
>> Hi Andy,
>>
>> Did this fix
>> http://www.mail-archive.com/hbase-user@hadoop.apache.org/ 
>> msg07734.html
>> ? I missed the issue and had not yet time to test this (as 0.20 does
>> not have the junit 4 test). If so, does Sandy know already I assume?
>>
>> Thanks,
>> Lars
>
>
>
>

Re: svn commit: r894799 - in /hadoop/hbase/branches/0.20

Posted by Andrew Purtell <ap...@apache.org>.
Hey Lars,

The patch fixes the bug as described, on visual inspection. I made sure no mapreduce package tests broke before commit but did not write a unit test for it. We could use one.

  - Andy



----- Original Message ----
> From: Lars George <la...@gmail.com>
> To: hbase-dev@hadoop.apache.org
> Cc: apurtell <ap...@apache.org>
> Sent: Thu, December 31, 2009 2:05:12 AM
> Subject: Re: svn commit: r894799 - in /hadoop/hbase/branches/0.20
> 
> Hi Andy,
> 
> Did this fix 
> http://www.mail-archive.com/hbase-user@hadoop.apache.org/msg07734.html
> ? I missed the issue and had not yet time to test this (as 0.20 does
> not have the junit 4 test). If so, does Sandy know already I assume?
> 
> Thanks,
> Lars