You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by wu...@apache.org on 2022/04/08 06:54:32 UTC

[shardingsphere] branch 5.1.1-release updated: Remove synchronized (#16658)

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

wuweijie pushed a commit to branch 5.1.1-release
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git


The following commit(s) were added to refs/heads/5.1.1-release by this push:
     new 87a10842dca Remove synchronized (#16658)
87a10842dca is described below

commit 87a10842dca7aeda83d263bd6eb1bf097013734d
Author: gin <ja...@163.com>
AuthorDate: Fri Apr 8 14:54:21 2022 +0800

    Remove synchronized (#16658)
---
 .../manager/cluster/coordinator/future/lock/DistributeLockContext.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/shardingsphere-mode/shardingsphere-mode-type/shardingsphere-cluster-mode/shardingsphere-cluster-mode-core/src/main/java/org/apache/shardingsphere/mode/manager/cluster/coordinator/future/lock/DistributeLockContext.java b/shardingsphere-mode/shardingsphere-mode-type/shardingsphere-cluster-mode/shardingsphere-cluster-mode-core/src/main/java/org/apache/shardingsphere/mode/manager/cluster/coordinator/future/lock/DistributeLockContext.java
index e2b9b5bf0a7..2dc777e20e9 100644
--- a/shardingsphere-mode/shardingsphere-mode-type/shardingsphere-cluster-mode/shardingsphere-cluster-mode-core/src/main/java/org/apache/shardingsphere/mode/manager/cluster/coordinator/future/lock/DistributeLockContext.java
+++ b/shardingsphere-mode/shardingsphere-mode-type/shardingsphere-cluster-mode/shardingsphere-cluster-mode-core/src/main/java/org/apache/shardingsphere/mode/manager/cluster/coordinator/future/lock/DistributeLockContext.java
@@ -81,7 +81,7 @@ public final class DistributeLockContext implements LockContext {
     }
     
     @Override
-    public synchronized boolean isLockedSchema(final String schemaName) {
+    public boolean isLockedSchema(final String schemaName) {
         Preconditions.checkNotNull(schemaName, "Is locked schema args schema name can not be null.");
         return getGlobalLock(schemaName).map(shardingSphereGlobalLock -> shardingSphereGlobalLock.isLocked(schemaName)).orElse(false);
     }