You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by GitBox <gi...@apache.org> on 2022/11/17 07:51:22 UTC

[GitHub] [inlong] healchow commented on a diff in pull request #6564: [INLONG-6563][Manager] Fix the problem of no error message was displayed when deleting a group failed

healchow commented on code in PR #6564:
URL: https://github.com/apache/inlong/pull/6564#discussion_r1024852544


##########
inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/group/InlongGroupProcessService.java:
##########
@@ -289,7 +292,13 @@ private void invokeDeleteProcess(String groupId, String operator) {
         InlongGroupInfo groupInfo = groupService.doDeleteCheck(groupId, operator);
         // start to delete group process
         GroupResourceProcessForm form = genGroupResourceProcessForm(groupInfo, GroupOperateType.DELETE);
-        workflowService.start(ProcessName.DELETE_GROUP_PROCESS, operator, form);
+        WorkflowResult result = workflowService.start(ProcessName.DELETE_GROUP_PROCESS, operator, form);
+        List<TaskResponse> tasks = result.getNewTasks();
+        if (TaskStatus.FAILED.equals(tasks.get(tasks.size() - 1).getStatus())) {
+            String errMsg = String.format("failed to delete group process for groupId=%s", groupId);
+            LOGGER.error(errMsg);

Review Comment:
   1. We are all at least at the `info` level. No matter in the test or production environment, we use logs at the `info` level at least;
   2. The following `WorkflowListenerException` also uses this error message, so it reuses the error message.



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org