You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by kx...@apache.org on 2023/06/25 14:38:00 UTC

[doris] 03/05: [bugfix](workloadgroup) could not upgrade from 2.0 alpha (#21149)

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

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

commit 1fa23d25a9936ceb6af2698717e69df3899cd47e
Author: yiguolei <67...@qq.com>
AuthorDate: Sun Jun 25 22:02:53 2023 +0800

    [bugfix](workloadgroup) could not upgrade from 2.0 alpha (#21149)
    
    
    
    ---------
    
    Co-authored-by: yiguolei <yi...@gmail.com>
---
 .../org/apache/doris/resource/workloadgroup/WorkloadGroup.java | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/fe/fe-core/src/main/java/org/apache/doris/resource/workloadgroup/WorkloadGroup.java b/fe/fe-core/src/main/java/org/apache/doris/resource/workloadgroup/WorkloadGroup.java
index 1276f54db8..cb2c151215 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/resource/workloadgroup/WorkloadGroup.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/resource/workloadgroup/WorkloadGroup.java
@@ -281,8 +281,14 @@ public class WorkloadGroup implements Writable, GsonPostProcessable {
 
     @Override
     public void gsonPostProcess() throws IOException {
-        String memoryLimitString = properties.get(MEMORY_LIMIT);
-        this.memoryLimitPercent = Double.parseDouble(memoryLimitString.substring(0, memoryLimitString.length() - 1));
+        if (properties.containsKey(MEMORY_LIMIT)) {
+            String memoryLimitString = properties.get(MEMORY_LIMIT);
+            this.memoryLimitPercent = Double.parseDouble(memoryLimitString.substring(0,
+                    memoryLimitString.length() - 1));
+        } else {
+            this.memoryLimitPercent = 100;
+            this.properties.put(MEMORY_LIMIT, "100%");
+        }
         this.initQueryQueue();
     }
 }


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