Monoid & MonoidK

In continuation to previous post. There is no documentation for MonoidK (Monoid for higher Kinds) on the cats site, hence let me try explaining it. Though Monoid first. Monoid `Monoid[T]` technically is a Semigroup with an `empty`/`Identity` function. i.e. There are two main properties: Associativity…

Cats

Cats is a simple and concise functional programming library for Scala. It appeals to me for its compactness and simpler class hierarchy. I have no formal education in category theory. But I am a student of theoretical Mathematics and have studied Abstract Algebra. Though I…

Asynchronous Distributed Key-Value DB

I have developed a simple-beta version of an synchronous distributed key-value database. It is simple and quite robust and I plan to make it not so-simple and open to other languages (apart from JVM based ones) in the future :).¬†You can download it and start…

Atomicity from single-cycle compare & swap

There is a wonderful function defined in scala.concurrent.Future¬†trait called onComplete. Here is the declaration: There is one key-point in the documentation which says : If the future has already been completed, this will either be applied immediately or be scheduled asynchronously. The reason I call…