You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by se...@apache.org on 2017/01/23 18:45:15 UTC
[3/4] flink git commit: [FLINK-4917] [streaming api] Deprecate
"CheckpointedAsynchronously" interface
[FLINK-4917] [streaming api] Deprecate "CheckpointedAsynchronously" interface
This closes #3087
Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/083152c6
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/083152c6
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/083152c6
Branch: refs/heads/release-1.2
Commit: 083152c63086e465b71c702815a2d22af686f122
Parents: 159f51b
Author: mtunique <oa...@gmail.com>
Authored: Tue Jan 10 23:05:44 2017 +0800
Committer: Stephan Ewen <se...@apache.org>
Committed: Mon Jan 23 19:18:59 2017 +0100
----------------------------------------------------------------------
.../api/checkpoint/CheckpointedAsynchronously.java | 15 +++++++++++++++
1 file changed, 15 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flink/blob/083152c6/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/checkpoint/CheckpointedAsynchronously.java
----------------------------------------------------------------------
diff --git a/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/checkpoint/CheckpointedAsynchronously.java b/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/checkpoint/CheckpointedAsynchronously.java
index 8ad5ad0..6fcc1d5 100644
--- a/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/checkpoint/CheckpointedAsynchronously.java
+++ b/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/checkpoint/CheckpointedAsynchronously.java
@@ -36,6 +36,21 @@ import java.io.Serializable;
* <p>To be able to support asynchronous snapshots, the state returned by the
* {@link #snapshotState(long, long)} method is typically a copy or shadow copy
* of the actual state.</p>
+ * @deprecated Please use {@link ListCheckpointed} and {@link CheckpointedFunction}.
+ *
+ * The short cut replacement via {@link ListCheckpointed}
+ * <pre>{@code
+ * public class ExampleOperator implements ListCheckpointed<Integer> {
+ *
+ * public List<Integer> snapshotState(long checkpointId, long timestamp) throws Exception {
+ * return Collections.singletonList(this.value);
+ * }
+ *
+ * public void restoreState(List<Integer> state) throws Exception {
+ * this.value = state.get(0);
+ * }
+ * }</pre>
*/
+@Deprecated
@PublicEvolving
public interface CheckpointedAsynchronously<T extends Serializable> extends Checkpointed<T> {}