|
|
@ -105,10 +105,7 @@ public class WorkflowExecuteThread implements Runnable { |
|
|
|
* runing TaskNode |
|
|
|
* runing TaskNode |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private final Map<Integer, ITaskProcessor> activeTaskProcessorMaps = new ConcurrentHashMap<>(); |
|
|
|
private final Map<Integer, ITaskProcessor> activeTaskProcessorMaps = new ConcurrentHashMap<>(); |
|
|
|
/** |
|
|
|
|
|
|
|
* task exec service |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
private final ExecutorService taskExecService; |
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* process instance |
|
|
|
* process instance |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -217,9 +214,6 @@ public class WorkflowExecuteThread implements Runnable { |
|
|
|
|
|
|
|
|
|
|
|
this.processInstance = processInstance; |
|
|
|
this.processInstance = processInstance; |
|
|
|
this.masterConfig = masterConfig; |
|
|
|
this.masterConfig = masterConfig; |
|
|
|
int masterTaskExecNum = masterConfig.getMasterExecTaskNum(); |
|
|
|
|
|
|
|
this.taskExecService = ThreadUtils.newDaemonFixedThreadExecutor("Master-Task-Exec-Thread", |
|
|
|
|
|
|
|
masterTaskExecNum); |
|
|
|
|
|
|
|
this.nettyExecutorManager = nettyExecutorManager; |
|
|
|
this.nettyExecutorManager = nettyExecutorManager; |
|
|
|
this.processAlertManager = processAlertManager; |
|
|
|
this.processAlertManager = processAlertManager; |
|
|
|
this.taskTimeoutCheckList = taskTimeoutCheckList; |
|
|
|
this.taskTimeoutCheckList = taskTimeoutCheckList; |
|
|
@ -228,8 +222,11 @@ public class WorkflowExecuteThread implements Runnable { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void run() { |
|
|
|
public void run() { |
|
|
|
try { |
|
|
|
try { |
|
|
|
|
|
|
|
if (!this.isStart()) { |
|
|
|
startProcess(); |
|
|
|
startProcess(); |
|
|
|
|
|
|
|
} else { |
|
|
|
handleEvents(); |
|
|
|
handleEvents(); |
|
|
|
|
|
|
|
} |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
|
logger.error("handler error:", e); |
|
|
|
logger.error("handler error:", e); |
|
|
|
} |
|
|
|
} |
|
|
|