Pavlin Radoslavov
Committed by Gerrit Code Review

Fix a bug inside DistributedLock.extendExpiration():

Return false (as per API) if we don't hold the lock.

Change-Id: Id3c314f6e374c92a73ce6f1aa4b6fbcef0a80697
......@@ -132,6 +132,7 @@ public class DistributedLock implements Lock {
if (!isLocked()) {
log.warn("Ignoring request to extend expiration for lock {}."
+ " ExtendExpiration must be called for locks that are already acquired.", path);
return false;
}
if (databaseService.putIfValueMatches(
......