diff --git a/changes/en-us/2.x.md b/changes/en-us/2.x.md index a44ec1d5aa0..b655da2930a 100644 --- a/changes/en-us/2.x.md +++ b/changes/en-us/2.x.md @@ -14,6 +14,7 @@ Add changes here for all PR submitted to the 2.x branch. - [[#6907](https://github.com/apache/incubator-seata/pull/6907)] fix the issue of Codecov not generating reports - [[#6923](https://github.com/apache/incubator-seata/pull/6923)] Enhance 401 Error Handling by Refreshing Token - [[#6925](https://github.com/apache/incubator-seata/pull/6925)] fix the issue in Raft model a follower's crash may lead to the continued use of expired tokens +- [[#6932](https://github.com/apache/incubator-seata/pull/6932)] when enabling local transactions, the lock contention failure in file & raft mode does not exit, leading to a lingering lock ### optimize: - [[#6826](https://github.com/apache/incubator-seata/pull/6826)] remove the branch registration operation of the XA read-only transaction diff --git a/changes/zh-cn/2.x.md b/changes/zh-cn/2.x.md index 05d217ae562..74c16200115 100644 --- a/changes/zh-cn/2.x.md +++ b/changes/zh-cn/2.x.md @@ -14,6 +14,7 @@ - [[#6907](https://github.com/apache/incubator-seata/pull/6907)] 修复Codecov未生成报告的问题 - [[#6923](https://github.com/apache/incubator-seata/pull/6923)] 增强 401 错误处理,通过刷新令牌 - [[#6925](https://github.com/apache/incubator-seata/pull/6925)] 修复Raft模式下,Follower崩溃可能导致Client继续使用过期令牌的问题 +- [[#6932](https://github.com/apache/incubator-seata/pull/6932)] 修复开启本地事务时file&raft模式下锁争抢失败未退出导致可能出现残留锁 ### optimize: diff --git a/server/src/main/java/org/apache/seata/server/storage/file/lock/FileLocker.java b/server/src/main/java/org/apache/seata/server/storage/file/lock/FileLocker.java index 4e5e484fc35..c9630e0aa10 100644 --- a/server/src/main/java/org/apache/seata/server/storage/file/lock/FileLocker.java +++ b/server/src/main/java/org/apache/seata/server/storage/file/lock/FileLocker.java @@ -108,12 +108,8 @@ public boolean acquireLock(List rowLocks, boolean autoCommit, boolean s failFast = true; break; } - if (canLock) { - canLock = false; - if (autoCommit) { - break; - } - } + canLock = false; + break; } } if (failFast) {