[DSIP-61][Master] Refactor thread pool and state event orchestration in master#16327
Conversation
d29aba5 to
d6052b8
Compare
| String[] processInstanceIdArray = processInstanceIds.split(Constants.COMMA); | ||
| List<String> errorMessage = new ArrayList<>(); | ||
| for (String strProcessInstanceId : processInstanceIdArray) { | ||
| int processInstanceId = Integer.parseInt(strProcessInstanceId); |
Check notice
Code scanning / CodeQL
Missing catch of NumberFormatException
| int processInstanceId = Integer.parseInt(strProcessInstanceId); | ||
| try { | ||
| execService.controlWorkflowInstance(loginUser, processInstanceId, executeType); | ||
| log.info("Success do action {} on workflowInstance: {}", executeType, processInstanceId); |
Check failure
Code scanning / CodeQL
Log Injection
| } catch (Exception e) { | ||
| errorMessage.add("Failed do action " + executeType + " on workflowInstance: " + processInstanceId | ||
| + "reason: " + e.getMessage()); | ||
| log.error("Failed do action {} on workflowInstance: {}, error: {}", executeType, processInstanceId, e); |
Check failure
Code scanning / CodeQL
Log Injection
|
d6052b8 to
465806d
Compare
465806d to
4adedb5
Compare
There was a problem hiding this comment.
CodeQL found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
4adedb5 to
0b40177
Compare
f5a524f to
c816086
Compare
41a627e to
a101f89
Compare
8999a0d to
2118c1f
Compare
646a458 to
02044d5
Compare
The coverage is incorrect
|
1ff6b24 to
ddf387f
Compare
5710bfd to
be08dfb
Compare
...hinscheduler/server/master/engine/task/lifecycle/handler/TaskStartLifecycleEventHandler.java
Outdated
Show resolved
Hide resolved
...er-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowEngine.java
Outdated
Show resolved
Hide resolved
...er-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowEngine.java
Outdated
Show resolved
Hide resolved
...uler-master/src/main/java/org/apache/dolphinscheduler/server/master/config/MasterConfig.java
Show resolved
Hide resolved
SbloodyS
left a comment
There was a problem hiding this comment.
LGTM. That's really a huge job. 👍🏻
...org/apache/dolphinscheduler/api/executor/workflow/PauseWorkflowInstanceExecutorDelegate.java
Outdated
Show resolved
Hide resolved
...dolphinscheduler/api/executor/workflow/RecoverSuspendedWorkflowInstanceExecutorDelegate.java
Show resolved
Hide resolved
.../java/org/apache/dolphinscheduler/api/executor/workflow/TriggerWorkflowExecutorDelegate.java
Show resolved
Hide resolved
.../java/org/apache/dolphinscheduler/api/executor/workflow/TriggerWorkflowExecutorDelegate.java
Show resolved
Hide resolved
...n/java/org/apache/dolphinscheduler/api/executor/workflow/WorkflowInstanceControlRequest.java
Outdated
Show resolved
Hide resolved
...rc/main/java/org/apache/dolphinscheduler/extract/master/transportor/ITaskExecutionEvent.java
Outdated
Show resolved
Hide resolved
| package org.apache.dolphinscheduler.extract.master.transportor; | ||
|
|
||
| public interface ITaskInstanceExecutionEvent { | ||
| public interface ITaskExecutionEvent { |
There was a problem hiding this comment.
Suggest to add event source, which can help troubleshoot.
There was a problem hiding this comment.
Yes, it is needed, e.g. distinguish the event from the task executor or user operation. I add todo here.
...aster/src/main/java/org/apache/dolphinscheduler/server/master/cluster/MasterSlotManager.java
Outdated
Show resolved
Hide resolved
...ter/src/main/java/org/apache/dolphinscheduler/server/master/engine/TaskGroupCoordinator.java
Show resolved
Hide resolved
...er-master/src/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowEngine.java
Show resolved
Hide resolved
...c/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowEventBusFireWorker.java
Show resolved
Hide resolved
...aster/src/main/java/org/apache/dolphinscheduler/server/master/engine/WorkflowRepository.java
Outdated
Show resolved
Hide resolved
...pache/dolphinscheduler/server/master/engine/command/handler/ReRunWorkflowCommandHandler.java
Outdated
Show resolved
Hide resolved
.../dolphinscheduler/server/master/engine/command/handler/RecoverFailureTaskCommandHandler.java
Show resolved
Hide resolved
...ain/java/org/apache/dolphinscheduler/server/master/engine/graph/AbstractSuccessorParser.java
Outdated
Show resolved
Hide resolved
...c/main/java/org/apache/dolphinscheduler/server/master/engine/graph/WorkflowGraphFactory.java
Show resolved
Hide resolved
| GLOBAL_MASTER_FAILOVER, | ||
| MASTER_FAILOVER, |
There was a problem hiding this comment.
It's better to add some comments for the difference.
|
|
||
| @Slf4j | ||
| @Component | ||
| public class PhysicalTaskExecutorClientDelegator implements ITaskExecutorClientDelegator { |
There was a problem hiding this comment.
Is the PhysicalTask means The tasks which execute on worker?
.../apache/dolphinscheduler/server/master/engine/task/statemachine/AbstractTaskStateAction.java
Outdated
Show resolved
Hide resolved
...n/java/org/apache/dolphinscheduler/server/master/runner/TaskExecutionRunnableRepository.java
Outdated
Show resolved
Hide resolved
...r/src/test/java/org/apache/dolphinscheduler/server/master/AbstractMasterIntegrationTest.java
Show resolved
Hide resolved
|





Purpose of the pull request
close #16423
Brief change log
Verify this pull request
This pull request is code cleanup without any test coverage.
(or)
This pull request is already covered by existing tests, such as (please describe tests).
(or)
This change added tests and can be verified as follows:
(or)
Pull Request Notice
Pull Request Notice
If your pull request contain incompatible change, you should also add it to
docs/docs/en/guide/upgrede/incompatible.md