Class FlinkSourceSplit<T>
- java.lang.Object
-
- org.apache.beam.runners.flink.translation.wrappers.streaming.io.source.FlinkSourceSplit<T>
-
- Type Parameters:
T- The output type of the encapsulated BeamSource.
- All Implemented Interfaces:
java.io.Serializable,org.apache.flink.api.connector.source.SourceSplit
public class FlinkSourceSplit<T> extends java.lang.Object implements org.apache.flink.api.connector.source.SourceSplit, java.io.SerializableA FlinkSourceSplitimplementation that encapsulates a BeamSource. This class also serves as the holder of the checkpoint state of the BeamReadercreated from the encapsulated source. So, the Source can recreate the Reader from the checkpointed state upon failure recovery.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FlinkSourceSplit(int splitIndex, org.apache.beam.sdk.io.Source<T> beamSplitSource)FlinkSourceSplit(int splitIndex, org.apache.beam.sdk.io.Source<T> beamSplitSource, byte @Nullable [] splitState, @Nullable org.apache.beam.sdk.io.UnboundedSource.CheckpointMark checkpointMark)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.beam.sdk.io.Source<T>getBeamSplitSource()@Nullable org.apache.beam.sdk.io.UnboundedSource.CheckpointMarkgetCheckpointMark()byte @Nullable []getSplitState()static <T> org.apache.flink.core.io.SimpleVersionedSerializer<FlinkSourceSplit<T>>serializer()java.lang.StringsplitId()intsplitIndex()java.lang.StringtoString()
-
-
-
Constructor Detail
-
FlinkSourceSplit
public FlinkSourceSplit(int splitIndex, org.apache.beam.sdk.io.Source<T> beamSplitSource)
-
FlinkSourceSplit
public FlinkSourceSplit(int splitIndex, org.apache.beam.sdk.io.Source<T> beamSplitSource, byte @Nullable [] splitState, @Nullable org.apache.beam.sdk.io.UnboundedSource.CheckpointMark checkpointMark)
-
-
Method Detail
-
splitIndex
public int splitIndex()
-
getSplitState
public byte @Nullable [] getSplitState()
-
getBeamSplitSource
public org.apache.beam.sdk.io.Source<T> getBeamSplitSource()
-
splitId
public java.lang.String splitId()
- Specified by:
splitIdin interfaceorg.apache.flink.api.connector.source.SourceSplit
-
getCheckpointMark
public @Nullable org.apache.beam.sdk.io.UnboundedSource.CheckpointMark getCheckpointMark()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
serializer
public static <T> org.apache.flink.core.io.SimpleVersionedSerializer<FlinkSourceSplit<T>> serializer()
-
-