Please log in to watch this conference skillscast.
In this talk, David will describe how they use Commutative Replicated Data Types (CRDTs) at Whisk to provide a seamless, cross-device shopping list. CRDTs are general-purpose patterns for achieving eventually-consistent synchronisation. They achieve this by communicating in operations - “diffs” between one state and the next - which have magical properties of being replayable (idempotence) in any order (commutativity). Operations can be recorded in an operations log and used to reconstruct current state on a client, whilst respecting that client’s own local state. One of the concerns with using CRDTs is that this log of operations can grow indefinitely.
Whisk is a shopping list app that connects online recipes to online and offline supermarkets. Their users build their shopping lists from online recipes using embedded widgets, browser extensions, our webapp, and our mobile apps. Their lists must stay in sync, or they won’t eat. To complicate matters, users carry their lists with them to supermarkets - the best naturally-occurring examples of Faraday cages. Whisk's apps must work seamlessly with very patchy networks, but also in fully offline mode. To achieve this, their apps use local storage, and sync mechanisms use CRDTs.
Whisk have implemented two specific CRDTs to support shopping lists at Whisk, provided to their clients through an API built with Scala and underpinned by Cassandra. David will describe their approach and architecture, and discuss some practical measures they've taken to address the problem of an ever-growing operations log.
This talk should appeal to anyone interested in cross-device data synchronisation, and practical applications of Scala.
YOU MAY ALSO LIKE:
- How the JVM executes Java (in London on 24th July 2017)
- Got The Perfect Agile Model? Here’s What You Should Know About Agnostic Agile (in London on 16th August 2017)
- Gojko Adzic's Impact Mapping Workshop (in London on 27th September 2017)
- Agile Testing & BDD eXchange 2017 (in London on 9th - 10th November 2017)