Neo4j Graph Database, from PHP
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Neo4j Graph Database, from PHP

on

  • 7,205 views

 

Statistics

Views

Total Views
7,205
Views on SlideShare
7,166
Embed Views
39

Actions

Likes
0
Downloads
24
Comments
0

2 Embeds 39

http://librosweb.es 29
http://eventifier.co 10

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Neo4j Graph Database, from PHP Presentation Transcript

  • 1. Neo4j Graph Database From PHP February 28, 2013 Confoo 2013, Montréal
  • 2. How I got here R.I.P.Had a short life, but left before it was too late.
  • 3. Why Neo4j?● Simple set-up● Well documented● Open source● ... with “Enterprise” support● Not purely academic
  • 4. What is a graph database?A database providing persistance for graphs.
  • 5. Ok, but what is a graph?
  • 6. Ok, but what is a graph?
  • 7. Neo4j Out of the BoxData: http://www.neo4j.org/develop/example_data
  • 8. Gremlin● Provides control over the traversal algorithm● Pipe & Filter – similar to jQuery● Works across different graph databases● Based on Groovy (limited to Java)
  • 9. Gremling.v(1) .in(COMPANION_OF) .out(APPEARED_IN) .has(title, "The Doctors Daughter") .back(2)
  • 10. Gremlin● Can modify the graph● Allows to run arbitrary code● Implementation not as stable in Neo4j
  • 11. CypherSTART doctor = node(1)MATCH doctor <-[:COMPANION_OF]- companion, companion -[:APPEARED_IN]-> episodeWHERE episode.title = "The Doctors Daughter"RETURN companion, companion.character
  • 12. Enough theoryNeo4j in action
  • 13. REST API● JSON over HTTP● Well supported● Used by the web admin● Meaningful work requires many HTTP requests● http://docs.neo4j.org/chunked/stable/rest-api.html
  • 14. everyman/neo4jphp● Complete? REST API implementation● Basic wrappers for all components● https://github.com/jadell/neo4jphp/wiki
  • 15. everyman/neo4jphp Pros: Cons:● Well maintained ● Tedious API● Good ● Error-prone documentation ● Low-level● Predictable behavior
  • 16. hirevoice/neo4jphp-ogm● Bias: I am the author● Inspired by Doctrine● Uses annotations on classes● Built on top of everyman/neo4jphp● https://github.com/lphuberdeau/Neo4j-PHP-OGM
  • 17. hirevoice/neo4jphp-ogm Pros: Cons:● Fast (bulk operations) ● Supported by me● Feels like Doctrine ● Skim● Benefits from type documentation checking ● Implementation still● Well tested partial● Bundles and modules available (many)
  • 18. Others● neoxygen/updown● neoxygen/neox● neoxygen/GraphQuest
  • 19. Demo Codehttps://github.com/lphuberdeau/confoo-demo
  • 20. ContactLouis-Philippe Huberdeau lp@huberdeau.info