ConcurrentReferenceHashMap
from hazelcast
re-packaged as a single dependency-free JAR. Released under the same license
as the original hazelcast code: Apache 2.
libraryDependencies += "io.github.alexarchambault" % "concurrent-reference-hash-map" % "1.1.0"
Use it in your code like
import concurrentrefhashmap.ConcurrentReferenceHashMap
val map = new ConcurrentReferenceHashMap[String, (Int, Int)](
16,
ConcurrentReferenceHashMap.ReferenceType.WEAK,
ConcurrentReferenceHashMap.ReferenceType.WEAK
)