Skip to content

Commit a5f358b

Browse files
author
宋光璠
committed
32
1 parent 59836c8 commit a5f358b

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

fe/fe-core/src/main/java/org/apache/doris/common/profile/SummaryProfile.java

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -284,10 +284,10 @@ public class SummaryProfile {
284284
private long nereidsLockTableFinishTime = -1;
285285

286286
@SerializedName(value = "memoryLimit")
287-
private long memoryLimit = 0;
287+
private int memoryLimit = 0;
288288

289289
@SerializedName(value = "cpuShare")
290-
private long cpuShare = -1;
290+
private int cpuShare = 0;
291291

292292
@SerializedName(value = "enableMemoryOvercommit")
293293
private long enableMemoryOvercommit = 0;
@@ -585,6 +585,8 @@ private void updateExecutionSummaryProfile() {
585585
RuntimeProfile.printCounter(queryWriteResultConsumeTime, TUnit.TIME_MS));
586586
executionSummaryProfile.addInfoString(CPU_SHARE,
587587
RuntimeProfile.printCounter(cpuShare, TUnit.DOUBLE_VALUE));
588+
executionSummaryProfile.addInfoString(MEMORY_LIMIT,
589+
RuntimeProfile.printCounter(memoryLimit, TUnit.DOUBLE_VALUE));
588590
setTransactionSummary();
589591

590592
if (Config.isCloudMode()) {
@@ -658,10 +660,14 @@ public void setNereidsLockTableFinishTime(long lockTableFinishTime) {
658660
this.nereidsLockTableFinishTime = lockTableFinishTime;
659661
}
660662

661-
public void setCpuShare(long cpuShare) {
663+
public void setCpuShare(int cpuShare) {
662664
this.cpuShare = cpuShare;
663665
}
664666

667+
public void setMemoryLimit(int memoryLimit) {
668+
this.memoryLimit = memoryLimit;
669+
}
670+
665671
public void setNereidsCollectTablePartitionFinishTime(long collectTablePartitionFinishTime) {
666672
this.nereidsCollectTablePartitionFinishTime = collectTablePartitionFinishTime;
667673
}

fe/fe-core/src/main/java/org/apache/doris/qe/StmtExecutor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,7 @@ private Map<String, String> getSummaryInfo(boolean isFinished) {
350350
if (!list.isEmpty()) {
351351
WorkloadGroup wg = list.get(0);
352352
getSummaryProfile().setCpuShare(wg.getMaxCpuPercent());
353-
builder.memoryLimit(String.valueOf(wg.getMaxMemoryPercent()));
353+
getSummaryProfile().setMemoryLimit(wg.getMaxMemoryPercent());
354354
}
355355
} catch (UserException e) {
356356
throw new RuntimeException(e);

0 commit comments

Comments
 (0)