public class TableMutationOutputFormat
extends org.apache.hadoop.mapreduce.OutputFormat<org.ojai.Value,org.ojai.store.DocumentMutation>
implements org.apache.hadoop.conf.Configurable
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
OUTPUT_TABLE
Job parameter that specifies the output table.
|
Constructor and Description |
---|
TableMutationOutputFormat() |
Modifier and Type | Method and Description |
---|---|
void |
checkOutputSpecs(org.apache.hadoop.mapreduce.JobContext context)
Checks if the output target exists.
|
org.apache.hadoop.conf.Configuration |
getConf()
Returns the current configuration.
|
org.apache.hadoop.mapreduce.OutputCommitter |
getOutputCommitter(org.apache.hadoop.mapreduce.TaskAttemptContext context)
Returns the output committer.
|
org.apache.hadoop.mapreduce.RecordWriter<org.ojai.Value,org.ojai.store.DocumentMutation> |
getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext context)
Creates a new DocumentMutation record writer.
|
void |
setConf(org.apache.hadoop.conf.Configuration arg0)
This function is used to set parameters in the configuration.
|
public static final java.lang.String OUTPUT_TABLE
public void setConf(org.apache.hadoop.conf.Configuration arg0)
setConf
in interface org.apache.hadoop.conf.Configurable
arg0
- Configuration object with parameters for TableOutputFormat.Configurable.setConf(
org.apache.hadoop.conf.Configuration)
public org.apache.hadoop.conf.Configuration getConf()
getConf
in interface org.apache.hadoop.conf.Configurable
Configurable.getConf()
public org.apache.hadoop.mapreduce.RecordWriter<org.ojai.Value,org.ojai.store.DocumentMutation> getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext context) throws java.io.IOException, java.lang.InterruptedException
getRecordWriter
in class org.apache.hadoop.mapreduce.OutputFormat<org.ojai.Value,org.ojai.store.DocumentMutation>
context
- The current task context.java.io.IOException
- When creating the writer fails.java.lang.InterruptedException
- When the jobs is cancelled.public void checkOutputSpecs(org.apache.hadoop.mapreduce.JobContext context) throws java.io.IOException, java.lang.InterruptedException
checkOutputSpecs
in class org.apache.hadoop.mapreduce.OutputFormat<org.ojai.Value,org.ojai.store.DocumentMutation>
context
- The current context.java.io.IOException
- When the check fails.java.lang.InterruptedException
- When the job is aborted.OutputFormat.checkOutputSpecs(org.apache.hadoop.mapreduce.JobContext)
public org.apache.hadoop.mapreduce.OutputCommitter getOutputCommitter(org.apache.hadoop.mapreduce.TaskAttemptContext context) throws java.io.IOException, java.lang.InterruptedException
getOutputCommitter
in class org.apache.hadoop.mapreduce.OutputFormat<org.ojai.Value,org.ojai.store.DocumentMutation>
context
- The current context.java.io.IOException
- When creating the committer fails.java.lang.InterruptedException
- When the job is aborted.OutputFormat.getOutputCommitter(org.apache.hadoop.mapreduce.TaskAttemptContext)