@Internal public class LoggerOutputFormat extends Object implements OutputFormat<String>
Constructor and Description |
---|
LoggerOutputFormat() |
Modifier and Type | Method and Description |
---|---|
void |
close()
Method that marks the end of the life-cycle of parallel output instance.
|
void |
configure(Configuration parameters)
Configures this output format.
|
void |
open(int taskNumber,
int numTasks)
Opens a parallel instance of the output format to store the result of its parallel instance.
|
void |
writeRecord(String record)
Adds a record to the output.
|
public void configure(Configuration parameters)
OutputFormat
This method is always called first on a newly instantiated output format.
configure
in interface OutputFormat<String>
parameters
- The configuration with all parameters.public void open(int taskNumber, int numTasks)
OutputFormat
When this method is called, the output format it guaranteed to be configured.
open
in interface OutputFormat<String>
taskNumber
- The number of the parallel instance.numTasks
- The number of parallel tasks.public void writeRecord(String record)
OutputFormat
When this method is called, the output format it guaranteed to be opened.
writeRecord
in interface OutputFormat<String>
record
- The records to add to the output.public void close()
OutputFormat
When this method is called, the output format it guaranteed to be opened.
close
in interface OutputFormat<String>
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.