summaryrefslogtreecommitdiffstats
path: root/resource-assignment/provider/src/main
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2018-12-19 00:39:38 +0000
committerGerrit Code Review <gerrit@onap.org>2018-12-19 00:39:38 +0000
commit4909ba923a36f53257597565583c20d57db0bcf1 (patch)
treee19297fe8743a42104c599df1ebc2bec0884998b /resource-assignment/provider/src/main
parent9eeae2fc1ca5fa3db7f6b44d1becca50eced40a6 (diff)
parent50a756f026b92c964924437c9cccc73b0554e135 (diff)
Merge "Fixed soanr issue in LockHelperImpl.java"
Diffstat (limited to 'resource-assignment/provider/src/main')
-rw-r--r--resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/LockHelperImpl.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/LockHelperImpl.java b/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/LockHelperImpl.java
index 1611b5372..0efd8977a 100644
--- a/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/LockHelperImpl.java
+++ b/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/LockHelperImpl.java
@@ -73,6 +73,7 @@ public class LockHelperImpl implements LockHelper {
try {
Thread.sleep(lockWait * 1000);
} catch (InterruptedException ex) {
+ log.error("Interrupted Exception", ex);
}
}
}
@@ -80,7 +81,7 @@ public class LockHelperImpl implements LockHelper {
@Override
public void unlock(Collection<String> lockNames, boolean force) {
- if (lockNames == null || lockNames.size() == 0) {
+ if (lockNames == null || lockNames.isEmpty()) {
return;
}
@@ -105,7 +106,7 @@ public class LockHelperImpl implements LockHelper {
}
public void tryLock(Collection<String> resourceNameList, String lockRequester, int lockTimeout /* Seconds */) {
- if (resourceNameList == null || resourceNameList.size() == 0) {
+ if (resourceNameList == null || resourceNameList.isEmpty()) {
return;
}