Interface Sink<InputT>
-
- Type Parameters:
InputT- The type of the sink's input
- All Superinterfaces:
Serializable
- All Known Subinterfaces:
StatefulSink<InputT,WriterStateT>,TwoPhaseCommittingSink<InputT,CommT>
@PublicEvolving public interface Sink<InputT> extends Serializable
Base interface for developing a sink. A basicSinkis a stateless sink that can flush data on checkpoint to achieve at-least-once consistency. Sinks with additional requirements should implementStatefulSinkorTwoPhaseCommittingSink.The
Sinkneeds to be serializable. All configuration should be validated eagerly. The respective sink writers are transient and will only be created in the subtasks on the taskmanagers.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceSink.InitContextThe interface exposes some runtime info for creating aSinkWriter.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SinkWriter<InputT>createWriter(Sink.InitContext context)Creates aSinkWriter.
-
-
-
Method Detail
-
createWriter
SinkWriter<InputT> createWriter(Sink.InitContext context) throws IOException
Creates aSinkWriter.- Parameters:
context- the runtime context.- Returns:
- A sink writer.
- Throws:
IOException- for any failure during creation.
-
-