You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2020/10/27 05:12:38 UTC

[GitHub] [incubator-doris] xinghuayu007 commented on a change in pull request #4796: [BUG] Catch retry submit exception

xinghuayu007 commented on a change in pull request #4796:
URL: https://github.com/apache/incubator-doris/pull/4796#discussion_r512420821



##########
File path: fe/fe-core/src/main/java/org/apache/doris/load/loadv2/BulkLoadJob.java
##########
@@ -233,7 +233,32 @@ public void onTaskFailed(long taskId, FailMsg failMsg) {
                 loadTask.updateRetryInfo();
                 idToTasks.put(loadTask.getSignature(), loadTask);
                 // load id will be added to loadStatistic when executing this task
-                Catalog.getCurrentCatalog().getLoadTaskScheduler().submit(loadTask);
+                boolean retrySuccessFlag = false;
+                while (loadTask.getRetryTime() > 0) {
+                    try {
+                        Catalog.getCurrentCatalog().getLoadTaskScheduler().submit(loadTask);
+                        retrySuccessFlag = true;
+                        break;
+                    } catch (Exception e) {
+                        try {
+                            Thread.sleep(100);
+                        } catch (InterruptedException ex) {
+                            LOG.warn("retry sublit task sleep failed. task_id:{}", id);
+                        }
+                        // retry task

Review comment:
       OK,Imodified it.




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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org