Class CommittableWithLineage<CommT>
- java.lang.Object
-
- org.apache.flink.streaming.api.connector.sink2.CommittableWithLineage<CommT>
-
- All Implemented Interfaces:
CommittableMessage<CommT>
@Experimental public class CommittableWithLineage<CommT> extends Object implements CommittableMessage<CommT>
Provides metadata. The exposed exchange type betweenCommittingSinkWriter
andCommitter
.
-
-
Field Summary
-
Fields inherited from interface org.apache.flink.streaming.api.connector.sink2.CommittableMessage
EOI
-
-
Constructor Summary
Constructors Constructor Description CommittableWithLineage(CommT committable, long checkpointId, int subtaskId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
long
getCheckpointIdOrEOI()
Returns the checkpoint id or EOI if this message belong to the final checkpoint or the batch commit.CommT
getCommittable()
int
getSubtaskId()
The subtask that created this committable.int
hashCode()
<NewCommT> CommittableWithLineage<NewCommT>
map(Function<CommT,NewCommT> mapper)
String
toString()
CommittableWithLineage<CommT>
withSubtaskId(int subtaskId)
Creates a shallow copy with the given subtaskId.
-
-
-
Constructor Detail
-
CommittableWithLineage
public CommittableWithLineage(CommT committable, long checkpointId, int subtaskId)
-
-
Method Detail
-
getCommittable
public CommT getCommittable()
-
getSubtaskId
public int getSubtaskId()
Description copied from interface:CommittableMessage
The subtask that created this committable.- Specified by:
getSubtaskId
in interfaceCommittableMessage<CommT>
-
getCheckpointIdOrEOI
public long getCheckpointIdOrEOI()
Description copied from interface:CommittableMessage
Returns the checkpoint id or EOI if this message belong to the final checkpoint or the batch commit.- Specified by:
getCheckpointIdOrEOI
in interfaceCommittableMessage<CommT>
-
map
public <NewCommT> CommittableWithLineage<NewCommT> map(Function<CommT,NewCommT> mapper)
-
withSubtaskId
public CommittableWithLineage<CommT> withSubtaskId(int subtaskId)
Creates a shallow copy with the given subtaskId.
-
-