diff --git a/fe/fe-core/src/main/java/org/apache/doris/common/profile/ProfileManager.java b/fe/fe-core/src/main/java/org/apache/doris/common/profile/ProfileManager.java index 2034ee931bacd5..927d5863d5a996 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/common/profile/ProfileManager.java +++ b/fe/fe-core/src/main/java/org/apache/doris/common/profile/ProfileManager.java @@ -198,7 +198,12 @@ public void addExecutionProfile(ExecutionProfile executionProfile) { } public ExecutionProfile getExecutionProfile(TUniqueId queryId) { - return this.queryIdToExecutionProfiles.get(queryId); + readLock.lock(); + try { + return this.queryIdToExecutionProfiles.get(queryId); + } finally { + readLock.unlock(); + } } public void pushProfile(Profile profile) { diff --git a/regression-test/suites/query_profile/dml_profile_safe.groovy b/regression-test/suites/query_profile/dml_profile_safe.groovy index 17618df34d13a0..9594fa1673dee7 100644 --- a/regression-test/suites/query_profile/dml_profile_safe.groovy +++ b/regression-test/suites/query_profile/dml_profile_safe.groovy @@ -60,7 +60,7 @@ def waitForProfile = { masterHTTPAddr, taskType, sqlToken -> return false } -suite("dml_profile_safe") { +suite("dml_profile_safe", "nonConcurrent") { sql """set enable_nereids_planner = true;""" sql """set enable_fallback_to_original_planner = false;"""