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

yiguolei 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 05e162074c7 branch-2.1: [fix](Export) fix a memory leak in the FE 
because of the ExportJob #44019 (#44089)
05e162074c7 is described below

commit 05e162074c7470a458a20ee1f648aa3a3055be25
Author: github-actions[bot] 
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Mon Nov 18 16:54:53 2024 +0800

    branch-2.1: [fix](Export) fix a memory leak in the FE because of the 
ExportJob #44019 (#44089)
    
    Cherry-picked from #44019
    
    Co-authored-by: Tiewei Fang <[email protected]>
---
 fe/fe-core/src/main/java/org/apache/doris/load/ExportJob.java | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/fe/fe-core/src/main/java/org/apache/doris/load/ExportJob.java 
b/fe/fe-core/src/main/java/org/apache/doris/load/ExportJob.java
index 9e50d931855..852c3ff94fe 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/load/ExportJob.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/load/ExportJob.java
@@ -705,6 +705,9 @@ public class ExportJob implements Writable {
         finishTimeMs = System.currentTimeMillis();
         failMsg = new ExportFailMsg(type, msg);
         jobExecutorList.clear();
+        selectStmtListPerParallel.clear();
+        allOutfileInfo.clear();
+        partitionToVersion.clear();
         if (FeConstants.runningUnitTest) {
             return;
         }
@@ -752,6 +755,9 @@ public class ExportJob implements Writable {
         outfileInfo = GsonUtils.GSON.toJson(allOutfileInfo);
         // Clear the jobExecutorList to release memory.
         jobExecutorList.clear();
+        selectStmtListPerParallel.clear();
+        allOutfileInfo.clear();
+        partitionToVersion.clear();
         Env.getCurrentEnv().getEditLog().logExportUpdateState(this, 
ExportJobState.FINISHED);
         LOG.info("finish export job {}", id);
     }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to