Chapter 7. Transactions
This chapter covers
- Why transactions are important
- How Neo4j handles transactions
- How to integrate Neo4j with other transaction management systems
- How to take advantage of transaction events
Neo4j differs from some other NoSQL technologies by being fully ACID-compliant (ACID being an acronym for atomic, consistent, isolated, durable). Being fully ACID-compliant means Neo4j offers the same guarantees you’d have if you were working with a traditional relational database system.
It’s important to have ACID guarantees when you work with Neo4j because it’s commonplace to mutate a number of graph entities (nodes, relationships, and index entries) within the same transaction. It’s also easier to reason about the behavior of systems that are ACID-compliant compared to eventually consistent systems, where you have no real guarantees about when your changes will be visible across a cluster, and compared to technologies where there are no transactions and therefore partial results of a larger business operation may become temporarily visible to competing transactions. The durability aspect of ACID transactions also provides a high degree of confidence that once your transaction is committed, the data won’t be lost.