* [Fix-4839][Server] Process cannot stop when killed with retry * [Fix-4839][Server] Process cannot stop when killed with retry
@@ -167,8 +167,8 @@ public class TaskInstanceServiceImpl extends BaseServiceImpl implements TaskInst
return result;
}
- // check whether the task instance state type is failure
- if (!task.getState().typeIsFailure()) {
+ // check whether the task instance state type is failure or cancel
+ if (!task.getState().typeIsFailure() && !task.getState().typeIsCancel()) {
putMsg(result, Status.TASK_INSTANCE_STATE_OPERATION_ERROR, taskInstanceId, task.getState().toString());
@@ -90,7 +90,7 @@ public enum ExecutionStatus {
* @return status
*/
public boolean typeIsFailure() {
- return this == FAILURE || this == NEED_FAULT_TOLERANCE || this == KILL;
+ return this == FAILURE || this == NEED_FAULT_TOLERANCE;
/**