diff --git a/java/com.sap.sailing.domain.shared.android/src/com/sap/sailing/util/impl/LockUtil.java b/java/com.sap.sailing.domain.shared.android/src/com/sap/sailing/util/impl/LockUtil.java index 873c7b04841..f260061151b 100644 --- a/java/com.sap.sailing.domain.shared.android/src/com/sap/sailing/util/impl/LockUtil.java +++ b/java/com.sap.sailing.domain.shared.android/src/com/sap/sailing/util/impl/LockUtil.java @@ -52,7 +52,7 @@ public class LockUtil { private static final int NUMBER_OF_SECONDS_TO_WAIT_FOR_LOCK = 5; private static final Logger logger = Logger.getLogger(Util.class.getName()); - private static final Map lastTimeWriteLockWasObtained = new ConcurrentHashMap/*TODO ConcurrentWeakHashMap*/(); + private static final Map lastTimeWriteLockWasObtained = new ConcurrentWeakHashMap(); /** * Tells how many other threads propagated which held lock to the key thread. During propagation, a lock is @@ -64,7 +64,7 @@ public class LockUtil { * The thread-specific value maps are used as monitor objects whenever decisions about thread-specific lock counts * need to be made. */ - private static final Map> propagationCounts = new ConcurrentHashMap/*TODO ConcurrentWeakHashMap*/>(); + private static final Map> propagationCounts = new ConcurrentWeakHashMap>(); /** * Counts the "virtual" locks. A "virtual" lock is obtained if and only if at the time of calling @@ -73,13 +73,13 @@ public class LockUtil { * always have a positive integer value. {@link #decrement(Lock, Map)} removes entries whose integer count would * go to 0. */ - private static final Map> virtualLockCounts = new ConcurrentHashMap/*TODO ConcurrentWeakHashMap*/>(); + private static final Map> virtualLockCounts = new ConcurrentWeakHashMap>(); /** * Redundant but easily accessible hold count per thread and lock. These are the actual lock hold counts as they are * recorded in the actual {@link NamedReentrantReadWriteLock} locks. */ - private static final Map> lockCounts = new ConcurrentHashMap/*TODO ConcurrentWeakHashMap*/>(); + private static final Map> lockCounts = new ConcurrentWeakHashMap>(); public static void lockForRead(NamedReentrantReadWriteLock lock) { acquireLockVirtuallyOrActually(lock, lock.readLock(), ReadOrWrite.READ);