@Internal public class RecordWriterOutput<OUT> extends Object implements Output<StreamRecord<OUT>>
Output
that sends data using a RecordWriter
.Constructor and Description |
---|
RecordWriterOutput(StreamRecordWriter<SerializationDelegate<StreamRecord<OUT>>> recordWriter,
TypeSerializer<OUT> outSerializer,
OutputTag outputTag,
StreamStatusProvider streamStatusProvider) |
Modifier and Type | Method and Description |
---|---|
void |
broadcastEvent(AbstractEvent event) |
void |
clearBuffers() |
void |
close()
Closes the collector.
|
<X> void |
collect(OutputTag<X> outputTag,
StreamRecord<X> record)
Emits a record the side output identified by the given
OutputTag . |
void |
collect(StreamRecord<OUT> record)
Emits a record.
|
void |
emitLatencyMarker(LatencyMarker latencyMarker) |
void |
emitStreamStatus(StreamStatus streamStatus) |
void |
emitWatermark(Watermark mark)
Emits a
Watermark from an operator. |
void |
flush() |
public RecordWriterOutput(StreamRecordWriter<SerializationDelegate<StreamRecord<OUT>>> recordWriter, TypeSerializer<OUT> outSerializer, OutputTag outputTag, StreamStatusProvider streamStatusProvider)
public void collect(StreamRecord<OUT> record)
Collector
collect
in interface Collector<StreamRecord<OUT>>
record
- The record to collect.public <X> void collect(OutputTag<X> outputTag, StreamRecord<X> record)
Output
OutputTag
.collect
in interface Output<StreamRecord<OUT>>
record
- The record to collect.public void emitWatermark(Watermark mark)
Output
Watermark
from an operator. This watermark is broadcast to all downstream
operators.
A watermark specifies that no element with a timestamp lower or equal to the watermark timestamp will be emitted in the future.
emitWatermark
in interface Output<StreamRecord<OUT>>
public void emitStreamStatus(StreamStatus streamStatus)
public void emitLatencyMarker(LatencyMarker latencyMarker)
emitLatencyMarker
in interface Output<StreamRecord<OUT>>
public void broadcastEvent(AbstractEvent event) throws IOException, InterruptedException
IOException
InterruptedException
public void flush() throws IOException
IOException
public void close()
Collector
close
in interface Collector<StreamRecord<OUT>>
public void clearBuffers()
Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.