hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dru Jensen <drujen...@gmail.com>
Subject Re: HBase MapReduce: wrong HStoreKey's row value passed into the map method
Date Mon, 04 Aug 2008 21:11:27 GMT
I saw this behavior using the "Text" object in 0.1.3.  When I replaced  
it with "HStoreKey", it fixed my problem.  I haven't tried "Text" in  
0.2.0.

On Aug 4, 2008, at 1:52 PM, stack wrote:

> Thats odd Ruslan.  Were you able to figure out whats going on?  Any  
> chance of your upgrading to 0.1.3, or better, to the new 0.2.0 RC?
> St.Ack
>
> Ruslan Salyakhov wrote:
>> Hi guys!
>> I'm running my MR job that based
>> on org.apache.hadoop.hbase.mapred.BuildTableIndex
>>
>> //map method:
>> @Override
>>
>> public void map(HStoreKey key, MapWritable value,
>>
>> OutputCollector<Text, MapWritable> output,
>>
>> Reporter reporter) throws IOException {
>>
>> MapWritable mw = new MapWritable();
>>
>> debug("row=" + HBaseUtils.utf8(key.getRow().getBytes()));
>>
>> //debug("row=" + new String(key.getRow().getBytes())); //same output
>>
>> ...
>>
>> }
>>
>>
>> For example, an input table has the following row's values:
>>
>> afg-041005-010.jpg
>>
>> web_afg_040405_001.jpg
>>
>> 6-F-2034C-010.jpg
>>
>>
>> debug output:
>>
>> afg-041005-010.jpg
>>
>> web_afg_040405_001.jpg
>>
>> 6-F-2034C-010.jpg1.jpg
>>
>>
>> Take a look at last row: "6-F-2034C-010.jpg1.jpg" - got unexpected  
>> suffix
>> "1.jpg" was arrived from the end of previous row.
>>
>> There is some buffer that should be reset I guess.
>>
>> Probably I'm doing something wrog...
>>
>>
>> Environment: hbase 0.1.2 and hadoop 0.16.4
>>
>>
>> Thanks an advance,
>>
>>
>> Ruslan
>>
>>
>


Mime
View raw message