diff --git a/spring-integration-redis/src/main/java/org/springframework/integration/redis/util/RedisLockRegistry.java b/spring-integration-redis/src/main/java/org/springframework/integration/redis/util/RedisLockRegistry.java index d0fa41ba26d..729b855fb2b 100644 --- a/spring-integration-redis/src/main/java/org/springframework/integration/redis/util/RedisLockRegistry.java +++ b/spring-integration-redis/src/main/java/org/springframework/integration/redis/util/RedisLockRegistry.java @@ -85,6 +85,7 @@ * @author Christian Tzolov * @author Eddie Cho * @author Myeonghyeon Lee + * @author Roman Zabaluev * * @since 4.0 * @@ -432,11 +433,14 @@ public final boolean tryLock(long time, TimeUnit unit) throws InterruptedExcepti } private boolean tryRedisLock(long time) throws ExecutionException, InterruptedException { - final boolean result = tryRedisLockInner(time); - if (result) { + final boolean acquired = tryRedisLockInner(time); + if (acquired) { + if (LOGGER.isDebugEnabled()) { + LOGGER.debug("Acquired lock; " + this); + } this.lockedAt = System.currentTimeMillis(); } - return result; + return acquired; } protected final Boolean obtainLock() {