yiguolei commented on code in PR #10719: URL: https://github.com/apache/doris/pull/10719#discussion_r917330602
########## fe/fe-core/src/main/java/org/apache/doris/alter/SchemaChangeJobV2.java: ########## @@ -494,22 +492,38 @@ protected void runRunningJob() throws AlterCancelException { List<AgentTask> tasks = schemaChangeBatchTask.getUnfinishedTasks(2000); for (AgentTask task : tasks) { if (task.getFailedTimes() >= 3) { - throw new AlterCancelException("schema change task failed after try three times: " - + task.getErrorMsg()); + task.setFinished(true); + AgentTaskQueue.removeTask(task.getBackendId(), TTaskType.ALTER, task.getSignature()); + LOG.warn("schema change task failed after try three times: " + task.getErrorMsg()); + if (!failedAgentTasks.containsKey(task.getTabletId())) { + failedAgentTasks.put(task.getTabletId(), Lists.newArrayList(task)); + } else { + failedAgentTasks.get(task.getTabletId()).add(task); + } + int expectSucceedTaskNum = tbl.getPartitionInfo() + .getReplicaAllocation(task.getPartitionId()).getTotalReplicaNum(); + int failedTaskCount = failedAgentTasks.get(task.getTabletId()).size(); Review Comment: why not use the replica num in config? -- 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-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org