@InterfaceAudience.Public public class TsvImporterTextMapper extends org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text,ImmutableBytesWritable,org.apache.hadoop.io.Text>
Constructor and Description |
---|
TsvImporterTextMapper() |
Modifier and Type | Method and Description |
---|---|
protected void |
doSetup(org.apache.hadoop.mapreduce.Mapper.Context context)
Handles common parameter initialization that a subclass might want to leverage.
|
org.apache.hadoop.mapreduce.Counter |
getBadLineCount() |
boolean |
getSkipBadLines() |
void |
incrementBadLineCount(int count) |
void |
map(org.apache.hadoop.io.LongWritable offset,
org.apache.hadoop.io.Text value,
org.apache.hadoop.mapreduce.Mapper.Context context)
Convert a line of TSV text into an HBase table row.
|
protected void |
setup(org.apache.hadoop.mapreduce.Mapper.Context context)
Handles initializing this class with objects specific to it (i.e., the parser).
|
public TsvImporterTextMapper()
public boolean getSkipBadLines()
public org.apache.hadoop.mapreduce.Counter getBadLineCount()
public void incrementBadLineCount(int count)
protected void setup(org.apache.hadoop.mapreduce.Mapper.Context context)
doSetup
. Hence a
subclass may choose to override this method and call doSetup
as well before
handling it's own custom params. nsetup
in class org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text,ImmutableBytesWritable,org.apache.hadoop.io.Text>
protected void doSetup(org.apache.hadoop.mapreduce.Mapper.Context context)
public void map(org.apache.hadoop.io.LongWritable offset, org.apache.hadoop.io.Text value, org.apache.hadoop.mapreduce.Mapper.Context context) throws IOException
map
in class org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text,ImmutableBytesWritable,org.apache.hadoop.io.Text>
IOException
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.