ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vkuliche...@apache.org
Subject [34/43] ignite git commit: IGNITE-2725: Hadoop: fixed assertion in CancelJobProcessor caused by invalid phase transition. This closes #627.
Date Tue, 12 Apr 2016 00:08:56 GMT
IGNITE-2725: Hadoop: fixed assertion in CancelJobProcessor caused by invalid phase transition.
This closes #627.


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

Branch: refs/heads/ignite-2949
Commit: 4367d3d6b84cbed9368667557a8535dbcc7e432d
Parents: e5485f6
Author: iveselovskiy <iveselovskiy@gridgain.com>
Authored: Mon Apr 11 13:02:02 2016 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Mon Apr 11 13:02:02 2016 +0300

----------------------------------------------------------------------
 .../processors/hadoop/jobtracker/HadoopJobTracker.java       | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/4367d3d6/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/jobtracker/HadoopJobTracker.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/jobtracker/HadoopJobTracker.java
b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/jobtracker/HadoopJobTracker.java
index f4cf892..cdd8103 100644
--- a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/jobtracker/HadoopJobTracker.java
+++ b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/jobtracker/HadoopJobTracker.java
@@ -1581,7 +1581,10 @@ public class HadoopJobTracker extends HadoopComponent {
 
         /** {@inheritDoc} */
         @Override protected void update(HadoopJobMetadata meta, HadoopJobMetadata cp) {
-            assert meta.phase() == PHASE_CANCELLING || err != null: "Invalid phase for cancel:
" + meta;
+            final HadoopJobPhase currPhase = meta.phase();
+
+            assert currPhase == PHASE_CANCELLING || currPhase == PHASE_COMPLETE
+                    || err != null: "Invalid phase for cancel: " + currPhase;
 
             Collection<Integer> rdcCp = new HashSet<>(cp.pendingReducers());
 
@@ -1599,7 +1602,8 @@ public class HadoopJobTracker extends HadoopComponent {
 
             cp.pendingSplits(splitsCp);
 
-            cp.phase(PHASE_CANCELLING);
+            if (currPhase != PHASE_COMPLETE && currPhase != PHASE_CANCELLING)
+                cp.phase(PHASE_CANCELLING);
 
             if (err != null)
                 cp.failCause(err);


Mime
View raw message