Skip to content

Commit

Permalink
[Bug] fix CheckPoint Failure Options dose not take effect (#4104)
Browse files Browse the repository at this point in the history
* fix(#4085): CheckPoint Failure Options dose not take effect

---------

Co-authored-by: benjobs <benjobs@apache.org>
  • Loading branch information
xiaows08 and wolfboys authored Oct 1, 2024
1 parent fd116a1 commit 1225b2b
Showing 1 changed file with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,10 @@ public String getPath() {
@Getter
@Setter
public static class Latest implements Serializable {

private CheckPoint completed;
private CheckPoint savepoint;
private CheckPoint failed;

@JsonIgnore
public List<CheckPoint> getLatestCheckpoint() {
Expand All @@ -108,6 +110,15 @@ public List<CheckPoint> 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;
}
}
Expand Down

0 comments on commit 1225b2b

Please sign in to comment.