Enum Buffer.DataType
- All Implemented Interfaces:
Serializable,Comparable<Buffer.DataType>
- Enclosing interface:
- Buffer
Used to identify the type of data contained in the
Buffer so that we can get the
information without deserializing the serialized data.
Notes: Currently, one byte is used to serialize the ordinal of Buffer.DataType in NettyMessage.BufferResponse, so the maximum number
of supported data types is 128.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionALIGNED_CHECKPOINT_BARRIERindicates that this buffer represents a serialized checkpoint barrier of aligned exactly-once checkpoint mode.ALIGNED_WATERMARK_EVENTindicates that this buffer represents a serializedWatermarkEvent, which needs to be aligned.DATA_BUFFERindicates that this buffer represents a non-event data buffer.DATA_BUFFER_WITH_CLEAR_ENDindicates that this buffer represents a non-event data buffer, and that at the end of this buffer there is no data cut and split into the next buffer.END_OF_DATAindicates that there will be no more data buffer in a subpartition.END_OF_PARTITIONmarks a subpartition as fully consumed.END_OF_SEGMENTindicates that a segment is finished in a subpartition.EVENT_BUFFERindicates that this buffer represents serialized data of an event.NONEindicates that there is no buffer.Same as EVENT_BUFFER, but the event has been prioritized (e.g. it skipped buffers).Indicates that this subpartition state is fully recovered (emitted).Contains the metadata used during a recovery process.TIMEOUTABLE_ALIGNED_CHECKPOINT_BARRIERindicates that this buffer represents a serialized checkpoint barrier of aligned exactly-once checkpoint mode, that can be time-out'ed to an unaligned checkpoint barrier.UNALIGNED_WATERMARK_EVENTindicates that this buffer represents a serializedWatermarkEvent, which does not need to be aligned. -
Method Summary
Modifier and TypeMethodDescriptionstatic Buffer.DataTypegetDataType(AbstractEvent event, boolean hasPriority) booleanbooleanbooleanisBuffer()booleanisEvent()booleanbooleanstatic Buffer.DataTypeReturns the enum constant of this type with the specified name.static Buffer.DataType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
NONE
NONEindicates that there is no buffer. -
DATA_BUFFER
DATA_BUFFERindicates that this buffer represents a non-event data buffer. -
EVENT_BUFFER
EVENT_BUFFERindicates that this buffer represents serialized data of an event. Note that this type can be further divided into more fine-grained event types likeALIGNED_CHECKPOINT_BARRIERand etc. -
PRIORITIZED_EVENT_BUFFER
Same as EVENT_BUFFER, but the event has been prioritized (e.g. it skipped buffers). -
ALIGNED_CHECKPOINT_BARRIER
ALIGNED_CHECKPOINT_BARRIERindicates that this buffer represents a serialized checkpoint barrier of aligned exactly-once checkpoint mode. -
TIMEOUTABLE_ALIGNED_CHECKPOINT_BARRIER
TIMEOUTABLE_ALIGNED_CHECKPOINT_BARRIERindicates that this buffer represents a serialized checkpoint barrier of aligned exactly-once checkpoint mode, that can be time-out'ed to an unaligned checkpoint barrier. -
RECOVERY_COMPLETION
Indicates that this subpartition state is fully recovered (emitted). Further data can be consumed after unblocking. -
END_OF_SEGMENT
END_OF_SEGMENTindicates that a segment is finished in a subpartition. -
DATA_BUFFER_WITH_CLEAR_END
DATA_BUFFER_WITH_CLEAR_ENDindicates that this buffer represents a non-event data buffer, and that at the end of this buffer there is no data cut and split into the next buffer. -
END_OF_DATA
END_OF_DATAindicates that there will be no more data buffer in a subpartition. -
END_OF_PARTITION
END_OF_PARTITIONmarks a subpartition as fully consumed. -
RECOVERY_METADATA
Contains the metadata used during a recovery process. -
ALIGNED_WATERMARK_EVENT
ALIGNED_WATERMARK_EVENTindicates that this buffer represents a serializedWatermarkEvent, which needs to be aligned. -
UNALIGNED_WATERMARK_EVENT
UNALIGNED_WATERMARK_EVENTindicates that this buffer represents a serializedWatermarkEvent, which does not need to be aligned.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
isBuffer
public boolean isBuffer() -
isEvent
public boolean isEvent() -
hasPriority
public boolean hasPriority() -
isBlockingUpstream
public boolean isBlockingUpstream() -
requiresAnnouncement
public boolean requiresAnnouncement() -
isPartialRecord
public boolean isPartialRecord() -
getDataType
-