Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FLINK-4985] [checkpointing] Report canceled / declined checkpoints t…
…o the Checkpoint Coordinator
- Loading branch information
1 parent
0a79dd5
commit 48a4813
Showing
31 changed files
with
643 additions
and
316 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
...src/main/java/org/apache/flink/runtime/checkpoint/decline/CheckpointDeclineException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Base class of all exceptions that indicate a declined checkpoint. | ||
*/ | ||
public abstract class CheckpointDeclineException extends Exception { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public CheckpointDeclineException(String message) { | ||
super(message); | ||
} | ||
|
||
public CheckpointDeclineException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
...che/flink/runtime/checkpoint/decline/CheckpointDeclineOnCancellationBarrierException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Exception indicating that a checkpoint was declined because a cancellation | ||
* barrier was received. | ||
*/ | ||
public final class CheckpointDeclineOnCancellationBarrierException extends CheckpointDeclineException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public CheckpointDeclineOnCancellationBarrierException() { | ||
super("Task received cancellation from one of its inputs"); | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
.../java/org/apache/flink/runtime/checkpoint/decline/CheckpointDeclineSubsumedException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Exception indicating that a checkpoint was declined because a newer checkpoint | ||
* barrier was received on an input before the pending checkpoint's barrier. | ||
*/ | ||
public final class CheckpointDeclineSubsumedException extends CheckpointDeclineException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public CheckpointDeclineSubsumedException(long newCheckpointId) { | ||
super("Checkpoint was canceled because a barrier from newer checkpoint " + newCheckpointId + " was received."); | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
...ache/flink/runtime/checkpoint/decline/CheckpointDeclineTaskNotCheckpointingException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Exception indicating that a checkpoint was declined because a task does not support | ||
* checkpointing. | ||
*/ | ||
public final class CheckpointDeclineTaskNotCheckpointingException extends CheckpointDeclineException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public CheckpointDeclineTaskNotCheckpointingException(String taskName) { | ||
super("Task '" + taskName + "'does not support checkpointing"); | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
...a/org/apache/flink/runtime/checkpoint/decline/CheckpointDeclineTaskNotReadyException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Exception indicating that a checkpoint was declined because a task was not | ||
* ready to perform a checkpoint. | ||
*/ | ||
public final class CheckpointDeclineTaskNotReadyException extends CheckpointDeclineException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public CheckpointDeclineTaskNotReadyException(String taskName) { | ||
super("Task " + taskName + " was not running"); | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
.../src/main/java/org/apache/flink/runtime/checkpoint/decline/InputEndOfStreamException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package org.apache.flink.runtime.checkpoint.decline; | ||
|
||
/** | ||
* Exception indicating that a checkpoint was declined because one of the input | ||
* stream reached its end before the alignment was complete. | ||
*/ | ||
public final class InputEndOfStreamException extends CheckpointDeclineException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
|
||
public InputEndOfStreamException() { | ||
super("Checkpoint was declined because one input stream is finished"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.