This is an automated email from the ASF dual-hosted git repository.

dataroaring pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-2.1 by this push:
     new d36ba97eae6 [fix](statistics) correct update rows when doing 
multi-table load (#39548)
d36ba97eae6 is described below

commit d36ba97eae62f564b15fc31509b346f5f4d3ddea
Author: zhengyu <freeman.zhang1...@gmail.com>
AuthorDate: Thu Aug 22 09:57:45 2024 +0800

    [fix](statistics) correct update rows when doing multi-table load (#39548)
    
    rows of only one table is updated correctly, need to merge all table
    commit infos.
    Signed-off-by: freemandealer <freeman.zhang1...@gmail.com>
---
 .../java/org/apache/doris/transaction/PublishVersionDaemon.java  | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git 
a/fe/fe-core/src/main/java/org/apache/doris/transaction/PublishVersionDaemon.java
 
b/fe/fe-core/src/main/java/org/apache/doris/transaction/PublishVersionDaemon.java
index ac1cbe9154c..d27c618c914 100644
--- 
a/fe/fe-core/src/main/java/org/apache/doris/transaction/PublishVersionDaemon.java
+++ 
b/fe/fe-core/src/main/java/org/apache/doris/transaction/PublishVersionDaemon.java
@@ -127,7 +127,14 @@ public class PublishVersionDaemon extends MasterDaemon {
             
partitionCommitInfos.addAll(tableCommitInfo.getIdToPartitionCommitInfo().values());
 
             try {
-                
beIdToBaseTabletIds.putAll(getBaseTabletIdsForEachBe(transactionState, 
tableCommitInfo));
+                Map<Long, Set<Long>> map = 
getBaseTabletIdsForEachBe(transactionState, tableCommitInfo);
+                map.forEach((beId, newSet) -> {
+                    beIdToBaseTabletIds.computeIfPresent(beId, (id, orgSet) -> 
{
+                        orgSet.addAll(newSet);
+                        return orgSet;
+                    });
+                    beIdToBaseTabletIds.putIfAbsent(beId, newSet);
+                });
             } catch (MetaNotFoundException e) {
                 LOG.warn("exception occur when trying to get rollup tablets 
info", e);
             }


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

Reply via email to