Shuntian (Vincent) is a Master’s student studying Computer Science at the University of Cambridge. He is passionate about distributed systems and functional programming, which makes Erlang a perfect programming community to join. He did his undergraduate project building a distributed Datalog engine in Erlang. In his Master’s project, he worked on extending the Mnesia database with eventual consistency as a collaboration between the University of Cambridge and Erlang Solutions.
Mnesia is an embedded database for Erlang/OTP applications that offers outstanding performance thanks to its tight integration with Erlang. However, its lack of conflict resolution after network partitions is a notable limitation that demands manual restart by developers to reconcile replicas. In this talk, I will discuss eventual consistency and CRDTs to achieve automatic conflict resolution within Mnesia. I will introduce Hypermnesia, an extension to Mnesia featuring a new access context async_ec that streamlines replica reconciliation after a partition. Hypermnesia is also designed with minimising overhead and out-of-box usage in mind. In the talk, I will present benchmarking results, and demonstrate practical examples of using Hypermnesia. This project is a collaboration between the University of Cambridge and Erlang Solutions.