This is an automated email from the ASF dual-hosted git repository. dataroaring pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push: new 3e142d818be [fix](load) fix broker load progress due to retry (#42959) 3e142d818be is described below commit 3e142d818be25f15f202f83f0c72718debff3cdd Author: Kaijie Chen <c...@apache.org> AuthorDate: Fri Nov 8 21:41:06 2024 +0800 [fix](load) fix broker load progress due to retry (#42959) ## Proposed changes Currently, when retrying a broker load, it will use a different `load_id` with the same `job_id`. The `total_scan_nums` in progress is accumulated by `job_id`. This will cause the `total_scan_nums` progress to be multiple of the actual scan nums. For example, suppose a 10 instance broker load gets retried: ``` initial (0/10) 0% -> retry (0/20) 0% -> finish (10/20) 50% ``` --- .../src/main/java/org/apache/doris/load/loadv2/LoadLoadingTask.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fe/fe-core/src/main/java/org/apache/doris/load/loadv2/LoadLoadingTask.java b/fe/fe-core/src/main/java/org/apache/doris/load/loadv2/LoadLoadingTask.java index 9b74f8718af..8510c2dc124 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/load/loadv2/LoadLoadingTask.java +++ b/fe/fe-core/src/main/java/org/apache/doris/load/loadv2/LoadLoadingTask.java @@ -20,6 +20,7 @@ package org.apache.doris.load.loadv2; import org.apache.doris.analysis.BrokerDesc; import org.apache.doris.analysis.UserIdentity; import org.apache.doris.catalog.Database; +import org.apache.doris.catalog.Env; import org.apache.doris.catalog.EnvFactory; import org.apache.doris.catalog.OlapTable; import org.apache.doris.common.Config; @@ -217,6 +218,8 @@ public class LoadLoadingTask extends LoadTask { UUID uuid = UUID.randomUUID(); this.loadId = new TUniqueId(uuid.getMostSignificantBits(), uuid.getLeastSignificantBits()); planner.updateLoadId(this.loadId); + // reset progress on each retry, otherwise the finished/total num will be incorrect + Env.getCurrentProgressManager().registerProgressSimple(String.valueOf(callback.getCallbackId())); } void settWorkloadGroups(List<TPipelineWorkloadGroup> tWorkloadGroups) { --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org