Convert the key and value type of this mergeable.
Convert the key and value type of this mergeable. Note this just bijects the Monoid, so the underlying monoid action is unchanged. For instance if you did a Bijection from Long to (Int,Int), the underlying monoid would still be long, not the default (Int,Int) monoid which works differently. Use of this probably requires careful design.
Create a mergeable by implementing merge with get followed by put.
Create a mergeable by implementing merge with get followed by put. Only safe if each key is owned by a single thread.
Create a mergeable by implementing merge with get followed by put.
Create a mergeable by implementing merge with get followed by put. Only safe if each key is owned by a single thread. This deletes zeros on put, but returns zero on empty (never returns None). Useful for sparse storage of counts, etc...
Implements multiMerge functionality in terms of an underlying store's multiGet and multiSet.
unpivot or uncurry this MergeableStore TODO: not clear is correct.
unpivot or uncurry this MergeableStore TODO: not clear is correct. It is injecting whatever Semigroup is present at call time not the actual Semigroup being used by the underlying store. I guess we need to unpivot the Semigroup as well (and might not even be well defined). If the Semigroup is the usual mapMonoid, everything is fine.
Use a StatefulSummer to buffer results before calling merge.
Use a StatefulSummer to buffer results before calling merge. Useful when merging to a remote store, of if you have some very hot keys
Some factory methods and combinators on MergeableStore