Enum Class BarrierCutStatus
- All Implemented Interfaces:
Serializable, Comparable<BarrierCutStatus>, Constable
Whether a barrier coordinator reached every partition of a cut.
The coordinator publishes both outcomes to __barrier_state. A complete
cut has a marker offset for every partition of the barrier group. A partial cut has
partitions that never received a marker, so no task can align on it: the missing
partitions would never reach the cut. BarrierCutReader returns complete
cuts only.
Example
if (cut.status() == BarrierCutStatus.PARTIAL) {
log.warn("epoch {} missed {}", cut.epoch(), cut.missing());
}
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionintcode()Returns the wire code the coordinator writes for this status.static BarrierCutStatusfromCode(int code) Maps a wire code onto a status.static BarrierCutStatusReturns the enum constant of this class with the specified name.static BarrierCutStatus[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
COMPLETE
Every partition of the barrier group received the epoch's marker. -
PARTIAL
One or more partitions never received the epoch's marker.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
code
-
fromCode
Maps a wire code onto a status.- Parameters:
code- the status byte read from a cut record- Returns:
- the matching status
- Throws:
ColumnarException- if no status carries the code
-