Data Structures and Algorithms: Linked Lists, Trees, Hash Maps
In the next part of this short video, Jim talks about the choice of data structures used for implementing Neo4j. An important property of Neo4j is what we call “index-free adjacency” — Graph traversals in Neo4j are (Pointer Size) * (Offset), which is an O(1) implementation. Of course, we pick and choose other data structures and algorithms for high performance graph storage. We have trees, for example, to implement indexes to find the starting points for graph traversal very affordably. We use lists in Neo4j for scenarios with modest amounts of data to enable high write performance — property chains, as an example.