You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2010/01/22 20:06:55 UTC

svn commit: r902224 - in /hadoop/hbase/trunk: CHANGES.txt src/java/org/apache/hadoop/hbase/mapreduce/package-info.java

Author: stack
Date: Fri Jan 22 19:06:55 2010
New Revision: 902224

URL: http://svn.apache.org/viewvc?rev=902224&view=rev
Log:
HBASE-2157 LATEST_TIMESTAMP not replaced by current timestamp in KeyValue

Modified:
    hadoop/hbase/trunk/CHANGES.txt
    hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/mapreduce/package-info.java

Modified: hadoop/hbase/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/CHANGES.txt?rev=902224&r1=902223&r2=902224&view=diff
==============================================================================
--- hadoop/hbase/trunk/CHANGES.txt (original)
+++ hadoop/hbase/trunk/CHANGES.txt Fri Jan 22 19:06:55 2010
@@ -330,6 +330,8 @@
    HBASE-2151  Remove onelab and include generated thrift classes in javadoc
                (Lars Francke via Stack)
    HBASE-2149  hbase.regionserver.global.memstore.lowerLimit is too low
+   HBASE-2157  LATEST_TIMESTAMP not replaced by current timestamp in KeyValue
+               (bulk loading)
 
   NEW FEATURES
    HBASE-1961  HBase EC2 scripts

Modified: hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/mapreduce/package-info.java
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/mapreduce/package-info.java?rev=902224&r1=902223&r2=902224&view=diff
==============================================================================
--- hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/mapreduce/package-info.java (original)
+++ hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/mapreduce/package-info.java Fri Jan 22 19:06:55 2010
@@ -116,8 +116,12 @@
 pull from your data source.  Your reduce task will need to be hooked up to
 {@link org.apache.hadoop.hbase.mapreduce.HFileOutputFormat}.  It expects to receive a row id and a value.
 The row id must be formatted as a {@link org.apache.hadoop.hbase.io.ImmutableBytesWritable} and the
-value as a {@link org.apache.hadoop.hbase.KeyValue} (A KeyValue holds he value for a cell and
-its coordinates; row/family/qualifier/timestamp, etc.).  Your reduce task
+value as a {@link org.apache.hadoop.hbase.KeyValue} (A KeyValue holds the value for a cell and
+its coordinates; row/family/qualifier/timestamp, etc.).  Note that you must
+specify a timestamp when you create the KeyValue in your map task
+otherwise the KeyValue will be created with the default LATEST_TIMESTAMP (Long.MAX_VALUE).  
+Use System.currentTimeMillis() if your data does not inherently bear a timestamp.
+Your reduce task
 will also need to emit the KeyValues in order.  See {@link org.apache.hadoop.hbase.mapreduce.KeyValueSortReducer}
 for an example reducer that emits KeyValues in order.
 </p>