Repository: flink
Updated Branches:
  refs/heads/master 665c7e399 -> fd872a149


[FLINK-4912] Introduce RECONCILIATING state in ExecutionGraph and Execution for 
JobManager failure recovery

This closes #3113


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/cc27f080
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/cc27f080
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/cc27f080

Branch: refs/heads/master
Commit: cc27f0803f4ed1d9799594c75ac00d0e14447479
Parents: 665c7e3
Author: 淘江 <taojiang....@alibaba-inc.com>
Authored: Fri Jan 13 16:41:37 2017 +0800
Committer: Stephan Ewen <se...@apache.org>
Committed: Thu Feb 9 15:03:47 2017 +0100

----------------------------------------------------------------------
 .../flink/runtime/execution/ExecutionState.java | 24 +++++++++++++-------
 .../flink/runtime/jobgraph/JobStatus.java       |  5 +++-
 2 files changed, 20 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/cc27f080/flink-runtime/src/main/java/org/apache/flink/runtime/execution/ExecutionState.java
----------------------------------------------------------------------
diff --git 
a/flink-runtime/src/main/java/org/apache/flink/runtime/execution/ExecutionState.java
 
b/flink-runtime/src/main/java/org/apache/flink/runtime/execution/ExecutionState.java
index e3e3256..d6ff0cd 100644
--- 
a/flink-runtime/src/main/java/org/apache/flink/runtime/execution/ExecutionState.java
+++ 
b/flink-runtime/src/main/java/org/apache/flink/runtime/execution/ExecutionState.java
@@ -25,16 +25,23 @@ package org.apache.flink.runtime.execution;
  * <pre>{@code
  *
  *     CREATED  -> SCHEDULED -> DEPLOYING -> RUNNING -> FINISHED
- *                     |            |          |
- *                     |            |   +------+
- *                     |            V   V
- *                     |         CANCELLING -----+----> CANCELED
- *                     |                         |
- *                     +-------------------------+
+ *            |         |            |          |
+ *            |         |            |   +------+
+ *            |         |            V   V
+ *            |         |         CANCELLING -----+----> CANCELED
+ *            |         |                         |
+ *            |        +-------------------------+
+ *            |
+ *            |                                   ... -> FAILED
+ *           V
+ *    RECONCILING  -> RUNNING | FINISHED | CANCELED | FAILED
  *
- *                                               ... -> FAILED
  * }</pre>
  *
+ * <p>It is possible to enter the {@code RECONCILING} state from {@code 
CREATED}
+ * state if job manager fail over, and the {@code RECONCILING} state can 
switch into
+ * any existing task state.</p>
+ *
  * <p>It is possible to enter the {@code FAILED} state from any other 
state.</p>
  *
  * <p>The states {@code FINISHED}, {@code CANCELED}, and {@code FAILED} are
@@ -56,8 +63,9 @@ public enum ExecutionState {
        
        CANCELED,
        
-       FAILED;
+       FAILED,
 
+       RECONCILING;
 
        public boolean isTerminal() {
                return this == FINISHED || this == CANCELED || this == FAILED;

http://git-wip-us.apache.org/repos/asf/flink/blob/cc27f080/flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/JobStatus.java
----------------------------------------------------------------------
diff --git 
a/flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/JobStatus.java 
b/flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/JobStatus.java
index 236a217..6a0ac97 100644
--- 
a/flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/JobStatus.java
+++ 
b/flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/JobStatus.java
@@ -51,7 +51,10 @@ public enum JobStatus {
         * The job has been suspended which means that it has been stopped but 
not been removed from a
         * potential HA job store.
         */
-       SUSPENDED(TerminalState.LOCALLY);
+       SUSPENDED(TerminalState.LOCALLY),
+
+       /** The job is currently reconciling and waits for task execution 
report to recover state. */
+       RECONCILING(TerminalState.NON_TERMINAL);
        
        // 
--------------------------------------------------------------------------------------------
 

Reply via email to