Immutable data structures are becoming more popular, with functional languages such as Clojure and Scala providing immutability by default. Immutability allows code to be more easily written, read and reasoned about. Using an accumulate-only data store can confer some of these benefits in the database layer, as well as make audit and historical querying simple. Implementation options vary, from specific accumulative data stores such as Datomic to simply using an “append-don’t-update” approach with a traditional database. Accumulate-only is a design strategy whereby data is removed via retraction rather than update; append-only is an implementation technique.
Immutable data structures are becoming more popular with functional languages such as Clojure providing immutability by default. Immutability allows code to be more easily written, read, and reasoned about. Using an append-only data store can confer some of these benefits in the database layer, as well as making audit and historical querying simple. Implementation options vary, from specific append-only data stores such as Datomic to simply using an “append-don’t-update” approach with a traditional database.