summaryrefslogtreecommitdiffstats
path: root/resource-assignment/provider
diff options
context:
space:
mode:
Diffstat (limited to 'resource-assignment/provider')
-rw-r--r--resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/SynchronizedFunction.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/SynchronizedFunction.java b/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/SynchronizedFunction.java
index f4df81b8b..9cce17a46 100644
--- a/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/SynchronizedFunction.java
+++ b/resource-assignment/provider/src/main/java/org/onap/ccsdk/sli/adaptors/lock/comp/SynchronizedFunction.java
@@ -21,6 +21,7 @@
package org.onap.ccsdk.sli.adaptors.lock.comp;
+import java.security.SecureRandom;
import java.util.Collection;
import java.util.HashSet;
import java.util.Set;
@@ -51,6 +52,7 @@ public abstract class SynchronizedFunction {
}
private static String generateLockRequester() {
- return "SynchronizedFunction-" + (int) (Math.random() * 1000000);
+ SecureRandom rand = new SecureRandom();
+ return "SynchronizedFunction-" + (int) (rand.nextDouble() * 1000000);
}
}