Package org.apache.hadoop.hbase.mapred
Class TableOutputFormat.TableRecordWriter
java.lang.Object
org.apache.hadoop.hbase.mapred.TableOutputFormat.TableRecordWriter
- All Implemented Interfaces:
org.apache.hadoop.mapred.RecordWriter<ImmutableBytesWritable,
Put>
- Enclosing class:
- TableOutputFormat
protected static class TableOutputFormat.TableRecordWriter
extends Object
implements org.apache.hadoop.mapred.RecordWriter<ImmutableBytesWritable,Put>
Convert Reduce output (key, value) to (HStoreKey, KeyedDataArrayWritable) and write to an HBase
table.
-
Field Summary
-
Constructor Summary
ConstructorDescriptionTableRecordWriter
(BufferedMutator mutator) Deprecated.since 2.0.0 and will be removed in 3.0.0.TableRecordWriter
(org.apache.hadoop.mapred.JobConf job) Instantiate a TableRecordWriter with a BufferedMutator for batch writing. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close
(org.apache.hadoop.mapred.Reporter reporter) void
write
(ImmutableBytesWritable key, Put value)
-
Field Details
-
m_mutator
-
conn
-
-
Constructor Details
-
TableRecordWriter
Deprecated.since 2.0.0 and will be removed in 3.0.0. Please use#TableRecordWriter(JobConf)
instead. This version does not clean up connections and will leak connections (removed in 2.0).Instantiate a TableRecordWriter with the HBase HClient for writing.- Throws:
IOException
- See Also:
-
TableRecordWriter
Instantiate a TableRecordWriter with a BufferedMutator for batch writing.- Throws:
IOException
-
-
Method Details
-
close
- Specified by:
close
in interfaceorg.apache.hadoop.mapred.RecordWriter<ImmutableBytesWritable,
Put> - Throws:
IOException
-
write
- Specified by:
write
in interfaceorg.apache.hadoop.mapred.RecordWriter<ImmutableBytesWritable,
Put> - Throws:
IOException
-