You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2021/03/02 12:27:09 UTC
[GitHub] [incubator-dolphinscheduler] JinyLeeChina opened a new pull request #4931: [Feature][JsonSplit] modify checkDAGRing and ProcessService method
JinyLeeChina opened a new pull request #4931:
URL: https://github.com/apache/incubator-dolphinscheduler/pull/4931
#4417
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-dolphinscheduler] CalvinKirs commented on a change in pull request #4931: [Feature][JsonSplit] modify checkDAGRing and ProcessService method
Posted by GitBox <gi...@apache.org>.
CalvinKirs commented on a change in pull request #4931:
URL: https://github.com/apache/incubator-dolphinscheduler/pull/4931#discussion_r586023753
##########
File path: dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/ProcessDefinitionServiceImpl.java
##########
@@ -1401,35 +1401,27 @@ private void importSubProcess(User loginUser, Project targetProject, ArrayNode j
return result;
}
-
/**
* whether the graph has a ring
*
- * @param taskNodeResponseList task node response list
+ * @param taskNodeList task node list
* @return if graph has cycle flag
*/
- private boolean graphHasCycle(List<TaskNode> taskNodeResponseList) {
- DAG<String, TaskNode, String> graph = new DAG<>();
-
- // Fill the vertices
- for (TaskNode taskNodeResponse : taskNodeResponseList) {
- graph.addNode(taskNodeResponse.getName(), taskNodeResponse);
- }
-
- // Fill edge relations
- for (TaskNode taskNodeResponse : taskNodeResponseList) {
- taskNodeResponse.getPreTasks();
- List<String> preTasks = JSONUtils.toList(taskNodeResponse.getPreTasks(), String.class);
+ private boolean graphHasCycle(List<TaskNode> taskNodeList) {
+ List<String> preTaskList = new ArrayList<>();
Review comment:
It’s best to make a judgment here to avoid NPE
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-dolphinscheduler] lenboo merged pull request #4931: [Feature][JsonSplit] modify checkDAGRing and ProcessService method
Posted by GitBox <gi...@apache.org>.
lenboo merged pull request #4931:
URL: https://github.com/apache/incubator-dolphinscheduler/pull/4931
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org