This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch branch-4.1
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-4.1 by this push:
new fbce8240436 branch-4.1: [enhancement](variable) newSessionVariable
uses read lock instead of write lock to reduce lock contention #60013 (#62367)
fbce8240436 is described below
commit fbce82404361f1862deeeb0c6d73700b9f3db5bb
Author: github-actions[bot]
<41898282+github-actions[bot]@users.noreply.github.com>
AuthorDate: Sat Apr 11 21:06:35 2026 +0800
branch-4.1: [enhancement](variable) newSessionVariable uses read lock
instead of write lock to reduce lock contention #60013 (#62367)
Cherry-picked from #60013
Co-authored-by: HonestManXin <[email protected]>
---
fe/fe-core/src/main/java/org/apache/doris/qe/VariableMgr.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fe/fe-core/src/main/java/org/apache/doris/qe/VariableMgr.java
b/fe/fe-core/src/main/java/org/apache/doris/qe/VariableMgr.java
index 8aaa7d452ad..c6f986875eb 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/qe/VariableMgr.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/qe/VariableMgr.java
@@ -262,11 +262,11 @@ public class VariableMgr {
}
public static SessionVariable newSessionVariable() {
- wlock.lock();
+ rlock.lock();
try {
return cloneSessionVariable(defaultSessionVariable);
} finally {
- wlock.unlock();
+ rlock.unlock();
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]