T
- The (java) type of the Trevni data to write.
Writes a directory of files per task, each comprising a single filesystem block. To reduce the number of files, increase the default filesystem block size for the job. Each task also requires enough memory to buffer a filesystem block.
public class AvroTrevniKeyOutputFormat<T> extends org.apache.hadoop.mapreduce.lib.output.FileOutputFormat<AvroKey<T>,org.apache.hadoop.io.NullWritable>
OutputFormat
that writes Avro data to
Trevni files.
This implement was modeled off
AvroKeyOutputFormat
to allow for easy
transition
FileOutputFormat for writing Trevni container files.
Since Trevni container files only contain records (not key/value pairs), this output format ignores the value.
Constructor and Description |
---|
AvroTrevniKeyOutputFormat() |
Modifier and Type | Method and Description |
---|---|
org.apache.hadoop.mapreduce.RecordWriter<AvroKey<T>,org.apache.hadoop.io.NullWritable> |
getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext context) |
checkOutputSpecs, getCompressOutput, getDefaultWorkFile, getOutputCommitter, getOutputCompressorClass, getOutputName, getOutputPath, getPathForWorkFile, getUniqueFile, getWorkOutputPath, setCompressOutput, setOutputCompressorClass, setOutputName, setOutputPath
public org.apache.hadoop.mapreduce.RecordWriter<AvroKey<T>,org.apache.hadoop.io.NullWritable> getRecordWriter(org.apache.hadoop.mapreduce.TaskAttemptContext context) throws IOException, InterruptedException
getRecordWriter
in class org.apache.hadoop.mapreduce.lib.output.FileOutputFormat<AvroKey<T>,org.apache.hadoop.io.NullWritable>
IOException
InterruptedException
Copyright © 2009–2021 The Apache Software Foundation. All rights reserved.