diff --git a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/metrics/flink/CheckPoints.java b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/metrics/flink/CheckPoints.java index 8aeadb1fcc..4d4084a419 100644 --- a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/metrics/flink/CheckPoints.java +++ b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/metrics/flink/CheckPoints.java @@ -17,13 +17,12 @@ package org.apache.streampark.console.core.metrics.flink; -import org.apache.streampark.console.core.enums.CheckPointStatus; -import org.apache.streampark.console.core.enums.CheckPointType; - import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import lombok.Getter; import lombok.Setter; +import org.apache.streampark.console.core.enums.CheckPointStatus; +import org.apache.streampark.console.core.enums.CheckPointType; import java.io.Serializable; import java.util.ArrayList; @@ -98,6 +97,7 @@ public String getPath() { public static class Latest implements Serializable { private CheckPoint completed; private CheckPoint savepoint; + private CheckPoint failed; @JsonIgnore public List getLatestCheckpoint() { @@ -108,6 +108,13 @@ public List getLatestCheckpoint() { if (savepoint != null) { checkPoints.add(savepoint); } + if (failed != null) { + if (completed == null) { + checkPoints.add(failed); + } else { + if (failed.getId() > completed.getId()) checkPoints.add(failed); + } + } return checkPoints; } }