Introducing Neo4j   Your Next Database       Max De Marzi
About Me    Built the Neography Gem (Ruby    Wrapper to the Neo4j REST API)    Playing with Neo4j since 10/2009•   My Blog...
Agenda• What is a Graph?• What is a Graph Database?• What can you do with a Graph Database?
What is a Graph?• An abstract representation of a set of objects  where some pairs are connected by links.             Obj...
Different Kinds of Graphs• Undirected Graph• Directed Graph• Pseudo Graph• Multi Graph• Hyper Graph
More Kinds of Graphs• Weighted Graph• Labeled Graph• Property Graph
What is a Graph Database?• A database with an explicit graph structure• Each node knows its adjacent nodes• As the number ...
Good For•   Highly connected data (social networks)•   Recommendations (e-commerce)•   Path Finding (how do I know you?)• ...
Not so good for• Set Operations:  – Union  – Intersection  – Cross Joins• Ginormous Amounts of Data  – Billions ok, Trilli...
What is Neo4j?• A Graph Database + Lucene Index• Property Graph• Full ACID (atomicity, consistency, isolation,  durability...
Neo4j + Ruby
Neo4j Data Browser
Neo4j Console
Friends Graph Illustrated
Friends Graph
Relationships.both is actually creating two relationships.One incoming and one outgoing friends relationship.Each Relation...
Friends of Friends
All Simple PathsSimple paths means no loops allowed
Shortest Path
Cypher : Neo4j Query LanguageASCII ART FTW: a--b, a-->b, a<--c
Neoflix: Movie Recommenderhttp://neoflix.herokuapp.com/
http://getvouched.com
Neo4j and Heroku Challengehttp://neo4j-challenge.herokuapp.com/
Questions?  ?
Thank you! http://maxdemarzi.com
Intro to Neo4j with Ruby
Intro to Neo4j with Ruby
Intro to Neo4j with Ruby
Upcoming SlideShare
Loading in...5
×

Intro to Neo4j with Ruby

12,999

Published on

A quick introduction to Graphs, Neo4j and neography.

Published in: Technology
0 Comments
11 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
12,999
On Slideshare
0
From Embeds
0
Number of Embeds
6
Actions
Shares
0
Downloads
161
Comments
0
Likes
11
Embeds 0
No embeds

No notes for slide
  • An undirected graph is one in which edges have no orientation. The edge (a, b) is identical to the edge (b, a).A directed graph or digraph is an ordered pair D = (V, A)A pseudo graph is a graph with loopsA multi graph allows for multiple edges between nodesA hyper graph allows an edge to join more than two nodes
  • A weighted graph has a number assigned to each edgeAlabeled graph has a label assigned to each node or edgeA property graph has keys and values for each node or edge
  • Atomic = all or nothing, consistent = stay consistent from one tx to another, isolation = no tx will mess with another tx, durability = once tx committed, it stays
  • Intro to Neo4j with Ruby

    1. 1. Introducing Neo4j Your Next Database Max De Marzi
    2. 2. About Me Built the Neography Gem (Ruby Wrapper to the Neo4j REST API) Playing with Neo4j since 10/2009• My Blog: http://maxdemarzi.com• Find me on Twitter: @maxdemarzi• Email me: maxdemarzi@gmail.com• GitHub: http://github.com/maxdemarzi
    3. 3. Agenda• What is a Graph?• What is a Graph Database?• What can you do with a Graph Database?
    4. 4. What is a Graph?• An abstract representation of a set of objects where some pairs are connected by links. Object (Vertex, Node) Link (Edge, Arc, Relationship)
    5. 5. Different Kinds of Graphs• Undirected Graph• Directed Graph• Pseudo Graph• Multi Graph• Hyper Graph
    6. 6. More Kinds of Graphs• Weighted Graph• Labeled Graph• Property Graph
    7. 7. What is a Graph Database?• A database with an explicit graph structure• Each node knows its adjacent nodes• As the number of nodes increases, the cost of a local step (or hop) remains the same
    8. 8. Good For• Highly connected data (social networks)• Recommendations (e-commerce)• Path Finding (how do I know you?)• A* (Least Cost path)• Data First Schema (bottom-up, but you still need to design)
    9. 9. Not so good for• Set Operations: – Union – Intersection – Cross Joins• Ginormous Amounts of Data – Billions ok, Trillions not so much.
    10. 10. What is Neo4j?• A Graph Database + Lucene Index• Property Graph• Full ACID (atomicity, consistency, isolation, durability)• High Availability (with Enterprise Edition)• 32 Billion Nodes, 32 Billion Relationships, 64 Billion Properties• Embedded Server• REST API
    11. 11. Neo4j + Ruby
    12. 12. Neo4j Data Browser
    13. 13. Neo4j Console
    14. 14. Friends Graph Illustrated
    15. 15. Friends Graph
    16. 16. Relationships.both is actually creating two relationships.One incoming and one outgoing friends relationship.Each Relationship in Neo4j only goes in one direction.
    17. 17. Friends of Friends
    18. 18. All Simple PathsSimple paths means no loops allowed
    19. 19. Shortest Path
    20. 20. Cypher : Neo4j Query LanguageASCII ART FTW: a--b, a-->b, a<--c
    21. 21. Neoflix: Movie Recommenderhttp://neoflix.herokuapp.com/
    22. 22. http://getvouched.com
    23. 23. Neo4j and Heroku Challengehttp://neo4j-challenge.herokuapp.com/
    24. 24. Questions? ?
    25. 25. Thank you! http://maxdemarzi.com
    1. A particular slide catching your eye?

      Clipping is a handy way to collect important slides you want to go back to later.

    ×