#22035 Make it possible to use anything as the key in a map
- All Map types are now generic in their key: ORMap, ORMultiMap, LWWMap, PNCounterMap - test for binary compatibility with previous version for serialization - entries are sorted for deterministic SHA-1 on same value
This commit is contained in:
parent
5c79b81e92
commit
8499ff6faf
28 changed files with 2231 additions and 584 deletions
|
|
@ -301,7 +301,7 @@ class DistributedDataDocSpec extends AkkaSpec(DistributedDataDocSpec.config) {
|
|||
def println(o: Any): Unit = ()
|
||||
//#pncountermap
|
||||
implicit val node = Cluster(system)
|
||||
val m0 = PNCounterMap.empty
|
||||
val m0 = PNCounterMap.empty[String]
|
||||
val m1 = m0.increment("a", 7)
|
||||
val m2 = m1.decrement("a", 2)
|
||||
val m3 = m2.increment("b", 1)
|
||||
|
|
@ -337,7 +337,7 @@ class DistributedDataDocSpec extends AkkaSpec(DistributedDataDocSpec.config) {
|
|||
def println(o: Any): Unit = ()
|
||||
//#ormultimap
|
||||
implicit val node = Cluster(system)
|
||||
val m0 = ORMultiMap.empty[Int]
|
||||
val m0 = ORMultiMap.empty[String, Int]
|
||||
val m1 = m0 + ("a" -> Set(1, 2, 3))
|
||||
val m2 = m1.addBinding("a", 4)
|
||||
val m3 = m2.removeBinding("a", 2)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue