Introduction to Neo4j

Graph Database?

RDBMS

Graph DB

Migration

  • Create model
  • Load data
  • Query data
SELECT name FROM Person
LEFT JOIN Person_Department
  ON Person.Id = Person_Department.PersonId
LEFT JOIN Department
  ON Department.Id = Person_Department.DepartmentId
WHERE Department.name = "IT Department"
MATCH (p:Person)<-[:EMPLOYEE]-(d:Department)
WHERE d.name = "IT Department"
RETURN p.name

TL;DR

  • ACID
  • Clustered
  • Bilions of entities
  • Readable queries
  • High performance
  • Optional schema

Community vs Enterprise

  • clustered replication
  • cache sharding
  • fail-over
  • high-availability
  • live backups
  • advanced monitoring

Run with Docker

docker run \
    --publish=7474:7474 --publish=7687:7687 \
    --volume=$HOME/neo4j/data:/data \
    neo4j

Basics

Live demo!

Introduction to Neo4j

By Paweł Lewtak

Introduction to Neo4j

  • 266