SlideShare una empresa de Scribd logo
1 de 49
Descargar para leer sin conexión
Neo4j from the Command Line
Perspective (Introduction)
JUG MK | Skopje | 02.10.2013
2
Speaker Profile
Patrick Baumgartner
•  Senior Software Consultant | Partner @ Swiftmind
•  Spring Framework, OSGi, Neo4j
•  Spring Trainer, Neo4j Fanboy, Agilista
•  Co-Author of „OSGi für Praktiker“
•  Co-Organizer of Neo4j Meetup Zurich
•  @patbaumgartner
3
Swiftmind
Your experts for Enterprise Java
Areas of expertise
•  Java EE
•  Spring Framework
•  OSGi
•  Agile Methodologies
•  Software Engineering Best Practices
Headquarter
•  Zürich, Schweiz
•  @swiftmind
•  http://www.swiftmind.com
4
Agenda
•  Introduction to Graphs
•  Use cases
•  Neo4j
•  Querying
•  Import / Export
•  Tools und APIs
•  Polyglot Persistence
•  Q & A
5
New Demands on Data Access
•  Structured and
unstructured data
•  Massive amounts of data
•  Inexpensive horizontal
scaling
•  Apps and data in the
cloud
•  Social network features
•  …
6
New Types of Data Stores
7
NoSQL
Data Volume
Data Complexity
Key-Value Stores
Column Family
Document Databases
Graph Databases
Relational Databases
90% of all use cases
8
Property Graph Model
•  Graphs are made of
–  Vertices / Nodes
–  Edges / Relationships
–  Properties
Alice
Bob
Car
name:Bob
age:63
sex:male
name:Alice
age:21
sex:female
type:car
vendor:tesla
type:OWNS
type:DRIVES
9
Where is my graph?
Use cases
10
Social Data
Alice
Carol Luke
Bob
Sam
Pete
KNOWS
KNOWS
KNOWS
KNOWS
11
Is it the only use case?
Social Graph
12
Spatial Data
1
2 5
3
13
8
ROAD
ROAD
ROAD
type:ROADlength:3km
type:Hotel
name:Radisson
lat:47.452549
long:8.564615
type:Hotel
name:Widder
lat:47.373517
long:8.539252
13
Social & Spatial Data
Alice
Mat 5
Bob
13
8
ROAD
ROAD
LIKES
KNOWS
type:Hotel
name:Radisson Blu
lat:47.452549
long:8.564615
14
Financial Data
Alice
Hotel Luke
Bank
ATM
Pete
WITHDRAW
TRANSFER
OWNS
15
Other graph use cases?
16
Railroad in Switzerland
17
Your Business Domain
Process
KPI
Device
Activity
Function
Service
CONTAINS
DEPENDS
18
Neo4j
The Big Picture
19
Neo4j – Big Picture
•  Most used graph data base
–  Robust & Mature: in production 24/7 since 2003
–  Community: Ecosystem with Tools, Bindings,
Frameworks
•  Licenses
–  AGPLv3 Community Edition – OpenSource
–  Advanced/Enterprise – for commercial applications
•  Neo Technology
–  Development & Support
–  ~ 50 Persons / 6 Countries / 3 Continents
20
Features
•  Object oriented, flexible network structure
•  ACID transactions
•  Horizontal scalable
•  Java API
–  Java, Groovy, Scala, JRuby
•  Runtime
–  Standalone Server
–  Embedded Database
•  Disk based storage manager
•  Plugin and testing support
21
How do I find my data?
Querying
22
Graph Querying
•  How do I query the right nodes from the graph?
–  Tell me all friends of friends of friends who liked the
movie XYZ with more than 3 stars
–  ...
•  Querying methods
–  Traversing with Neo4j API
–  Traversal descriptions
–  Graph algorithms
–  Index queries
–  Cypher queries
23
Neo4j API
Node bob = ...;	
	
for ((Relationship rel: bob.getRelationships(RelTypes.KNOWS)) {	
Node friend = rel.getEndNode();	
System.out.println(friend.getProperty("name"));	
}	
•  Simple, but very low level API
•  To verbose for complex traversals
24
Traversal API
•  Querying API for graphs
•  Describes paths trough the graph
•  Call back based
•  Fluent API
•  Several predefined constructs
•  Neo4j implements the following graph algorithms:
–  A*
–  Dijkstra
–  pathsWithLength
–  shortestPath
–  allSimplePaths
–  allPaths
25
Traversal API – Constructs
26
Example: Traversal API
TraversalDescription directFriends = Traversal.description()	
	 	.breadthFirst()	
	 	.relationships(RelTypes.KNOWS)	
	 	.evaluator(Evaluators.toDepth(1))	
	 	.evaluator(Evaluators.excludeStartPosition());	
	
	
for(Path p : directFriends.traverse(bob)) {	
	System.out.println(p.endNode().getProperty(„firstname“));	
}
27
Index Queries
•  Support for node and relationship
indices
•  Lucene as default implementation
node id property value
15 name Alice
15 yearOfBirth 1972
16 name Bob
46 name Carol
46 yearOfBirth 1983
28
Cypher Query Language
•  Graph query language similar to SQL
•  Declarative language
•  Defines „What“ and not „How“
•  Uses pattern matching
•  Support for
–  Filters
–  Pagination
•  Supports CRUD functionality
29
Cypher Query Language – Elemente
Element Description
START Start element(s) (index- or id-lookup)
MATCH Pattern to find nodes, describes paths
(a) –[knows]-> (b)
WHERE Result filter (boolean expression)
SKIP LIMIT Pagination
RETURN Defines return elements
ORDER BY Sorting by properties
PARAMETERS Parameter-Map, die im Cypher mittels Key oder
Position verwendet werden kann
CREATE Creates node nodes and relations
SET Updates properties on nodes and relations
DELETE Deletes unused nodes or relationships
30
Example: Cypher Query
String query = "START person=node(12) “	
	+ “MATCH person-[:KNOWS]-friend “	
	+ “RETURN friend“;	
	
	
ExecutionEngine engine = new ExecutionEngine(graphDb);	
ExecutionResult result = engine.execute(query);	
	 	 		
Iterator<Object> column = result.columnAs("friend");	
while(column.hasNext()) {	
	Node friendNode = (Node)column.next();	
	System.out.println(friendNode.getProperty(PROP_FIRSTNAME));	
}
person friend
KNOWS
31
Example: Cypher Create Query
CREATE (carol {name:“Carol“}) return carol; 	
	
+------------------------+	
| carol 	 |	
+------------------------+	
| Node[1]{name:“carol“} |	
+------------------------+	
	
START carol=node(1) CREATE (bob {name:“Bob"}), 	
	 (bob)-[:knows]->(carol) return carol;	
	
	
START carol=node(1) 	
CREATE (apple {name:“Apple“,type:“Fruit“}), 	
(carol)-[:owns {number: 5}]->(apple);	
Carol Bob
KNOWS
Carol
Carol Apple
type: Fruit
OWNS
number: 5
32
Shipping data
Import / Export – Node Manipulation
33
Node Creation with Java
org.neo4j.graphdb.GraphDatabaseService graphDb = 	 	 	
	 	new GraphDatabaseFactory().newEmbeddedDatabase(DB_PATH);	
Transaction tx = graphDb.beginTx();	
	
try {	
	Node peter = createNode(graphDb, “Alice");	
	Node carol = createNode(graphDb, “Carol"); 	 	 		
	peter.createRelationshipTo(carol, RelTypes.KNOWS);	
	..	
	tx.success();	
} finally {tx.finish();}	
	
public Node createNode(GraphDatabaseService graphDb, String firstname) {	
	Node person = graphDb.createNode();	
	person.setProperty(„firstname“, firstname);	
	return person;	
}
Alice Carol
KNOWS
34
NeoClipse
35
Spring Data Neo4j (SDN)
•  POJOs mapped as nodes or relationships – type safe
•  Works directly Database, typically embedded mode
•  Data is fetched very fast and lazy
•  Stores everything within a @Transaction
•  Uses heavily AspectJ magic to enhance the POJOs
•  …
36
Spring Data Neo4j – Entity
_type_: com.example.Person
name: "Alice"
age: 42
@NodeEntity
public class Person {
private String name;
private int age;
// getters/setters…
}
Person alice = new Person();
alice.setName("Alice");
alice.setAge(42);
alice.persist();
Node
37
Spring Data Neo4j – NodeEntity
@NodeEntity
public class Person {
private String name;
private int yearOfBirth;
@RelatedTo(type = "KNOWS", direction = Direction.OUTGOING)
private Set<Person> knownPersons;
public void knows(Person p) {
knownPersons.add(p);
}
public Set<Person> getFriends() {
return knownPersons;
}
}
Person alice = ...;
alice.knows(bob);
alice.knows(carol);
Alice Bob
KNOWS
Carol
KNOWS
38
Spring Data Neo4j – Relationship
@RelationshipEntity
public class Knows {
private int sinceYear;
public Knows since(int year) {
this.sinceYear = year;
return this;
}
}
@NodeEntity
public class Person {
public Known knows(Person p) {
return this.relateTo(p, Knows.class, "KNOWS");
}
}
Person alice = ...;
Person bob ...;
alice.knows(bob).since(2012); Alice Bob
KNOWS
since: 2012
39
Spring Data Neo4j – Repository
public interface PersonRepository extends
GraphRepository<Person> {
@Query("start person = {0} match ... return ...")
Iterable<Product> getOwnedServices(Person person);
Iterable<Person> findByName(String name);
Iterable<Person> findByNameLike(String name);
}
@Autowired
PersonRepository personRepository;
Person alice = personRepository.findByName("Alice");
40
Thinkerpop Blueprint
Thinkerpop Blueprint
Extensions
•  GraphML Reader/Writer
Library
•  GraphSon Reader/Writer
Library
•  GML Reader/Writer Library
•  Java Universal Network/
Graph Framework
41
GraphML
•  GraphML (http://graphml.graphdrawing.org/ )
–  Standardized format
–  Tool support
–  Pure and simple XML
<graph id="G" edgedefault="directed"> 	
<node id="n0"/> 	
<node id="n1"/>	
	 <edge source="n0" target="n1"/>	
</graph>
42
Neo4j Tools
•  GraphML
–  Gremlin Plugin (no further development)
–  Thinkerpop Blueprint Extensions
•  CSV
–  BatchInserter
–  ParallelBatchInserter
43
Useful tools for your daily work
Tools & APIs
44
Tools & APIs (2)
•  Web console
–  Data overview
–  Querying and visual graph presentation
–  „Command line“
•  Neo4j Shell
–  Command line
–  Sends UNIX-like Commands via RMI (cd, ls, pwd)
–  Cypher Queries Support
•  REST API
–  JSON
–  Clients for Java, .NET, PHP, Ruby, …
•  Neoclipse
–  Visual presentation of the graph
–  Filter options for partial graph presentation
45
What?! Your app uses only one DB?
Polyglot Persistence
46
Polyglot Persistence
Web shop application
User Sessions Shopping Cart Recommendations
Product Catalog Analytics Financial Data
Redis Riak Neo4j
MongoDB Casandra MySQL
47
Neo4j on Meetup.com
48
Q&A
49
Thank you!
Patrick Baumgartner, @patbaumgartner
patrick.baumgartner [at] swiftmind [dot] com
http://www.swiftmind.com @swiftmind

Más contenido relacionado

La actualidad más candente

Java Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBJava Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBMongoDB
 
Hands on Training – Graph Database with Neo4j
Hands on Training – Graph Database with Neo4jHands on Training – Graph Database with Neo4j
Hands on Training – Graph Database with Neo4jSerendio Inc.
 
Introduction to couch_db
Introduction to couch_dbIntroduction to couch_db
Introduction to couch_dbRomain Testard
 
Morphia, Spring Data & Co.
Morphia, Spring Data & Co.Morphia, Spring Data & Co.
Morphia, Spring Data & Co.Tobias Trelle
 
Java Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBJava Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBTobias Trelle
 
Graph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4jGraph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4jNeo4j
 
Java development with MongoDB
Java development with MongoDBJava development with MongoDB
Java development with MongoDBJames Williams
 
Morphia: Simplifying Persistence for Java and MongoDB
Morphia:  Simplifying Persistence for Java and MongoDBMorphia:  Simplifying Persistence for Java and MongoDB
Morphia: Simplifying Persistence for Java and MongoDBJeff Yemin
 
Simplifying Persistence for Java and MongoDB with Morphia
Simplifying Persistence for Java and MongoDB with MorphiaSimplifying Persistence for Java and MongoDB with Morphia
Simplifying Persistence for Java and MongoDB with MorphiaMongoDB
 
Challenges in knowledge graph visualization
Challenges in knowledge graph visualizationChallenges in knowledge graph visualization
Challenges in knowledge graph visualizationGraphAware
 
Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...Neo4j
 
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...Neo4j
 
JSLT: JSON querying and transformation
JSLT: JSON querying and transformationJSLT: JSON querying and transformation
JSLT: JSON querying and transformationLars Marius Garshol
 
Spring Data, Jongo & Co.
Spring Data, Jongo & Co.Spring Data, Jongo & Co.
Spring Data, Jongo & Co.Tobias Trelle
 
Neo4j Stored Procedure Training Part 1
Neo4j Stored Procedure Training Part 1Neo4j Stored Procedure Training Part 1
Neo4j Stored Procedure Training Part 1Max De Marzi
 

La actualidad más candente (17)

greenDAO
greenDAOgreenDAO
greenDAO
 
Grails and Neo4j
Grails and Neo4jGrails and Neo4j
Grails and Neo4j
 
Java Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBJava Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDB
 
Hands on Training – Graph Database with Neo4j
Hands on Training – Graph Database with Neo4jHands on Training – Graph Database with Neo4j
Hands on Training – Graph Database with Neo4j
 
Introduction to couch_db
Introduction to couch_dbIntroduction to couch_db
Introduction to couch_db
 
Morphia, Spring Data & Co.
Morphia, Spring Data & Co.Morphia, Spring Data & Co.
Morphia, Spring Data & Co.
 
Java Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDBJava Persistence Frameworks for MongoDB
Java Persistence Frameworks for MongoDB
 
Graph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4jGraph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4j
 
Java development with MongoDB
Java development with MongoDBJava development with MongoDB
Java development with MongoDB
 
Morphia: Simplifying Persistence for Java and MongoDB
Morphia:  Simplifying Persistence for Java and MongoDBMorphia:  Simplifying Persistence for Java and MongoDB
Morphia: Simplifying Persistence for Java and MongoDB
 
Simplifying Persistence for Java and MongoDB with Morphia
Simplifying Persistence for Java and MongoDB with MorphiaSimplifying Persistence for Java and MongoDB with Morphia
Simplifying Persistence for Java and MongoDB with Morphia
 
Challenges in knowledge graph visualization
Challenges in knowledge graph visualizationChallenges in knowledge graph visualization
Challenges in knowledge graph visualization
 
Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...Designing and Building a Graph Database Application – Architectural Choices, ...
Designing and Building a Graph Database Application – Architectural Choices, ...
 
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...
Object Graph Mapping with Spring Data Neo4j 3 - Nicki Watt & Michael Hunger @...
 
JSLT: JSON querying and transformation
JSLT: JSON querying and transformationJSLT: JSON querying and transformation
JSLT: JSON querying and transformation
 
Spring Data, Jongo & Co.
Spring Data, Jongo & Co.Spring Data, Jongo & Co.
Spring Data, Jongo & Co.
 
Neo4j Stored Procedure Training Part 1
Neo4j Stored Procedure Training Part 1Neo4j Stored Procedure Training Part 1
Neo4j Stored Procedure Training Part 1
 

Destacado

Reco4J @ London Meetup (June 26th)
Reco4J @ London Meetup (June 26th)Reco4J @ London Meetup (June 26th)
Reco4J @ London Meetup (June 26th)Alessandro Negro
 
Population Health Management
Population Health ManagementPopulation Health Management
Population Health ManagementDale Sanders
 
Microsoft: A Waking Giant in Healthcare Analytics and Big Data
Microsoft: A Waking Giant in Healthcare Analytics and Big DataMicrosoft: A Waking Giant in Healthcare Analytics and Big Data
Microsoft: A Waking Giant in Healthcare Analytics and Big DataDale Sanders
 
Reco4 @ Paris Meetup (May 20th)
Reco4 @ Paris Meetup (May 20th)Reco4 @ Paris Meetup (May 20th)
Reco4 @ Paris Meetup (May 20th)Alessandro Negro
 
OECD Health Indicators at a Glance
OECD Health Indicators at a GlanceOECD Health Indicators at a Glance
OECD Health Indicators at a GlanceDale Sanders
 
Reco4J @ Munich Meetup (April 18th)
Reco4J @ Munich Meetup (April 18th)Reco4J @ Munich Meetup (April 18th)
Reco4J @ Munich Meetup (April 18th)Alessandro Negro
 
Managing National Health: An Overview of Metrics & Options
Managing National Health: An Overview of Metrics & OptionsManaging National Health: An Overview of Metrics & Options
Managing National Health: An Overview of Metrics & OptionsDale Sanders
 
Break All The Rules: What the Leading Health Systems Do Differently with Anal...
Break All The Rules: What the Leading Health Systems Do Differently with Anal...Break All The Rules: What the Leading Health Systems Do Differently with Anal...
Break All The Rules: What the Leading Health Systems Do Differently with Anal...Dale Sanders
 
Is Big Data a Big Deal... or Not?
Is Big Data a Big Deal... or Not?Is Big Data a Big Deal... or Not?
Is Big Data a Big Deal... or Not?Dale Sanders
 
Precise Patient Registries for Clinical Research and Population Management
Precise Patient Registries for Clinical Research and Population ManagementPrecise Patient Registries for Clinical Research and Population Management
Precise Patient Registries for Clinical Research and Population ManagementDale Sanders
 
The 12 Criteria of Population Health Management
The 12 Criteria of Population Health ManagementThe 12 Criteria of Population Health Management
The 12 Criteria of Population Health ManagementDale Sanders
 
Predicting the Future of Predictive Analytics in Healthcare
Predicting the Future of Predictive Analytics in HealthcarePredicting the Future of Predictive Analytics in Healthcare
Predicting the Future of Predictive Analytics in HealthcareDale Sanders
 
HIMSS National Data Warehousing Webinar
HIMSS National Data Warehousing WebinarHIMSS National Data Warehousing Webinar
HIMSS National Data Warehousing WebinarDale Sanders
 
Healthcare Best Practices in Data Warehousing & Analytics
Healthcare Best Practices in Data Warehousing & AnalyticsHealthcare Best Practices in Data Warehousing & Analytics
Healthcare Best Practices in Data Warehousing & AnalyticsDale Sanders
 
An Overview of Disease Registries
An Overview of Disease RegistriesAn Overview of Disease Registries
An Overview of Disease RegistriesDale Sanders
 
Strategic Options for Analytics in Healthcare
Strategic Options for Analytics in HealthcareStrategic Options for Analytics in Healthcare
Strategic Options for Analytics in HealthcareDale Sanders
 
Choosing an Analytics Solution in Healthcare
Choosing an Analytics Solution in HealthcareChoosing an Analytics Solution in Healthcare
Choosing an Analytics Solution in HealthcareDale Sanders
 
Late Binding in Data Warehouses
Late Binding in Data WarehousesLate Binding in Data Warehouses
Late Binding in Data WarehousesDale Sanders
 
Healthcare Billing and Reimbursement: Starting from Scratch
Healthcare Billing and Reimbursement: Starting from ScratchHealthcare Billing and Reimbursement: Starting from Scratch
Healthcare Billing and Reimbursement: Starting from ScratchDale Sanders
 
Healthcare 2.0: The Age of Analytics
Healthcare 2.0: The Age of AnalyticsHealthcare 2.0: The Age of Analytics
Healthcare 2.0: The Age of AnalyticsDale Sanders
 

Destacado (20)

Reco4J @ London Meetup (June 26th)
Reco4J @ London Meetup (June 26th)Reco4J @ London Meetup (June 26th)
Reco4J @ London Meetup (June 26th)
 
Population Health Management
Population Health ManagementPopulation Health Management
Population Health Management
 
Microsoft: A Waking Giant in Healthcare Analytics and Big Data
Microsoft: A Waking Giant in Healthcare Analytics and Big DataMicrosoft: A Waking Giant in Healthcare Analytics and Big Data
Microsoft: A Waking Giant in Healthcare Analytics and Big Data
 
Reco4 @ Paris Meetup (May 20th)
Reco4 @ Paris Meetup (May 20th)Reco4 @ Paris Meetup (May 20th)
Reco4 @ Paris Meetup (May 20th)
 
OECD Health Indicators at a Glance
OECD Health Indicators at a GlanceOECD Health Indicators at a Glance
OECD Health Indicators at a Glance
 
Reco4J @ Munich Meetup (April 18th)
Reco4J @ Munich Meetup (April 18th)Reco4J @ Munich Meetup (April 18th)
Reco4J @ Munich Meetup (April 18th)
 
Managing National Health: An Overview of Metrics & Options
Managing National Health: An Overview of Metrics & OptionsManaging National Health: An Overview of Metrics & Options
Managing National Health: An Overview of Metrics & Options
 
Break All The Rules: What the Leading Health Systems Do Differently with Anal...
Break All The Rules: What the Leading Health Systems Do Differently with Anal...Break All The Rules: What the Leading Health Systems Do Differently with Anal...
Break All The Rules: What the Leading Health Systems Do Differently with Anal...
 
Is Big Data a Big Deal... or Not?
Is Big Data a Big Deal... or Not?Is Big Data a Big Deal... or Not?
Is Big Data a Big Deal... or Not?
 
Precise Patient Registries for Clinical Research and Population Management
Precise Patient Registries for Clinical Research and Population ManagementPrecise Patient Registries for Clinical Research and Population Management
Precise Patient Registries for Clinical Research and Population Management
 
The 12 Criteria of Population Health Management
The 12 Criteria of Population Health ManagementThe 12 Criteria of Population Health Management
The 12 Criteria of Population Health Management
 
Predicting the Future of Predictive Analytics in Healthcare
Predicting the Future of Predictive Analytics in HealthcarePredicting the Future of Predictive Analytics in Healthcare
Predicting the Future of Predictive Analytics in Healthcare
 
HIMSS National Data Warehousing Webinar
HIMSS National Data Warehousing WebinarHIMSS National Data Warehousing Webinar
HIMSS National Data Warehousing Webinar
 
Healthcare Best Practices in Data Warehousing & Analytics
Healthcare Best Practices in Data Warehousing & AnalyticsHealthcare Best Practices in Data Warehousing & Analytics
Healthcare Best Practices in Data Warehousing & Analytics
 
An Overview of Disease Registries
An Overview of Disease RegistriesAn Overview of Disease Registries
An Overview of Disease Registries
 
Strategic Options for Analytics in Healthcare
Strategic Options for Analytics in HealthcareStrategic Options for Analytics in Healthcare
Strategic Options for Analytics in Healthcare
 
Choosing an Analytics Solution in Healthcare
Choosing an Analytics Solution in HealthcareChoosing an Analytics Solution in Healthcare
Choosing an Analytics Solution in Healthcare
 
Late Binding in Data Warehouses
Late Binding in Data WarehousesLate Binding in Data Warehouses
Late Binding in Data Warehouses
 
Healthcare Billing and Reimbursement: Starting from Scratch
Healthcare Billing and Reimbursement: Starting from ScratchHealthcare Billing and Reimbursement: Starting from Scratch
Healthcare Billing and Reimbursement: Starting from Scratch
 
Healthcare 2.0: The Age of Analytics
Healthcare 2.0: The Age of AnalyticsHealthcare 2.0: The Age of Analytics
Healthcare 2.0: The Age of Analytics
 

Similar a Neo4j Introduction (for Techies)

Using Neo4j from Java
Using Neo4j from JavaUsing Neo4j from Java
Using Neo4j from JavaNeo4j
 
Cypher and apache spark multiple graphs and more in open cypher
Cypher and apache spark  multiple graphs and more in  open cypherCypher and apache spark  multiple graphs and more in  open cypher
Cypher and apache spark multiple graphs and more in open cypherNeo4j
 
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...Databricks
 
GreenDao Introduction
GreenDao IntroductionGreenDao Introduction
GreenDao IntroductionBooch Lin
 
PGQL: A Language for Graphs
PGQL: A Language for GraphsPGQL: A Language for Graphs
PGQL: A Language for GraphsJean Ihm
 
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...jexp
 
Discover GraphQL with Python, Graphene and Odoo
Discover GraphQL with Python, Graphene and OdooDiscover GraphQL with Python, Graphene and Odoo
Discover GraphQL with Python, Graphene and OdooOdoo
 
The openCypher Project - An Open Graph Query Language
The openCypher Project - An Open Graph Query LanguageThe openCypher Project - An Open Graph Query Language
The openCypher Project - An Open Graph Query LanguageNeo4j
 
Document Model for High Speed Spark Processing
Document Model for High Speed Spark ProcessingDocument Model for High Speed Spark Processing
Document Model for High Speed Spark ProcessingMongoDB
 
OSMC 2009 | Icinga by Icinga Team
OSMC 2009 | Icinga by Icinga TeamOSMC 2009 | Icinga by Icinga Team
OSMC 2009 | Icinga by Icinga TeamNETWAYS
 
GraphQL & Prisma from Scratch
GraphQL & Prisma from ScratchGraphQL & Prisma from Scratch
GraphQL & Prisma from ScratchNikolas Burk
 
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup Munich
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup MunichMorpheus SQL and Cypher® in Apache® Spark - Big Data Meetup Munich
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup MunichMartin Junghanns
 
Morpheus - SQL and Cypher in Apache Spark
Morpheus - SQL and Cypher in Apache SparkMorpheus - SQL and Cypher in Apache Spark
Morpheus - SQL and Cypher in Apache SparkHenning Kropp
 
Cassandra drivers and libraries
Cassandra drivers and librariesCassandra drivers and libraries
Cassandra drivers and librariesDuyhai Doan
 
Icinga 2009 at OSMC
Icinga 2009 at OSMCIcinga 2009 at OSMC
Icinga 2009 at OSMCIcinga
 
Processing Large Graphs
Processing Large GraphsProcessing Large Graphs
Processing Large GraphsNishant Gandhi
 
AgensGraph Presentation at PGConf.us 2017
AgensGraph Presentation at PGConf.us 2017AgensGraph Presentation at PGConf.us 2017
AgensGraph Presentation at PGConf.us 2017Kisung Kim
 
State of search | drupalcon dublin
State of search | drupalcon dublinState of search | drupalcon dublin
State of search | drupalcon dublinJoris Vercammen
 
Leveraging the Power of Graph Databases in PHP
Leveraging the Power of Graph Databases in PHPLeveraging the Power of Graph Databases in PHP
Leveraging the Power of Graph Databases in PHPJeremy Kendall
 

Similar a Neo4j Introduction (for Techies) (20)

Using Neo4j from Java
Using Neo4j from JavaUsing Neo4j from Java
Using Neo4j from Java
 
Cypher and apache spark multiple graphs and more in open cypher
Cypher and apache spark  multiple graphs and more in  open cypherCypher and apache spark  multiple graphs and more in  open cypher
Cypher and apache spark multiple graphs and more in open cypher
 
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...
Neo4j Morpheus: Interweaving Table and Graph Data with SQL and Cypher in Apac...
 
GreenDao Introduction
GreenDao IntroductionGreenDao Introduction
GreenDao Introduction
 
PGQL: A Language for Graphs
PGQL: A Language for GraphsPGQL: A Language for Graphs
PGQL: A Language for Graphs
 
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...
New Features in Neo4j 3.4 / 3.3 - Graph Algorithms, Spatial, Date-Time & Visu...
 
Discover GraphQL with Python, Graphene and Odoo
Discover GraphQL with Python, Graphene and OdooDiscover GraphQL with Python, Graphene and Odoo
Discover GraphQL with Python, Graphene and Odoo
 
The openCypher Project - An Open Graph Query Language
The openCypher Project - An Open Graph Query LanguageThe openCypher Project - An Open Graph Query Language
The openCypher Project - An Open Graph Query Language
 
Document Model for High Speed Spark Processing
Document Model for High Speed Spark ProcessingDocument Model for High Speed Spark Processing
Document Model for High Speed Spark Processing
 
OSMC 2009 | Icinga by Icinga Team
OSMC 2009 | Icinga by Icinga TeamOSMC 2009 | Icinga by Icinga Team
OSMC 2009 | Icinga by Icinga Team
 
GraphQL & Prisma from Scratch
GraphQL & Prisma from ScratchGraphQL & Prisma from Scratch
GraphQL & Prisma from Scratch
 
Naver_alternative_to_jpa
Naver_alternative_to_jpaNaver_alternative_to_jpa
Naver_alternative_to_jpa
 
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup Munich
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup MunichMorpheus SQL and Cypher® in Apache® Spark - Big Data Meetup Munich
Morpheus SQL and Cypher® in Apache® Spark - Big Data Meetup Munich
 
Morpheus - SQL and Cypher in Apache Spark
Morpheus - SQL and Cypher in Apache SparkMorpheus - SQL and Cypher in Apache Spark
Morpheus - SQL and Cypher in Apache Spark
 
Cassandra drivers and libraries
Cassandra drivers and librariesCassandra drivers and libraries
Cassandra drivers and libraries
 
Icinga 2009 at OSMC
Icinga 2009 at OSMCIcinga 2009 at OSMC
Icinga 2009 at OSMC
 
Processing Large Graphs
Processing Large GraphsProcessing Large Graphs
Processing Large Graphs
 
AgensGraph Presentation at PGConf.us 2017
AgensGraph Presentation at PGConf.us 2017AgensGraph Presentation at PGConf.us 2017
AgensGraph Presentation at PGConf.us 2017
 
State of search | drupalcon dublin
State of search | drupalcon dublinState of search | drupalcon dublin
State of search | drupalcon dublin
 
Leveraging the Power of Graph Databases in PHP
Leveraging the Power of Graph Databases in PHPLeveraging the Power of Graph Databases in PHP
Leveraging the Power of Graph Databases in PHP
 

Más de Patrick Baumgartner

Daten natuerlich modellieren und verarbeiten mit Neo4j
Daten natuerlich modellieren und verarbeiten mit Neo4jDaten natuerlich modellieren und verarbeiten mit Neo4j
Daten natuerlich modellieren und verarbeiten mit Neo4jPatrick Baumgartner
 
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow Zurich
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow ZurichHow to use NoSQL in Enterprise Java Applications - NoSQL Roadshow Zurich
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow ZurichPatrick Baumgartner
 
BED-Con - Tools für den täglichen Kampf als Entwickler
BED-Con - Tools für den täglichen Kampf als EntwicklerBED-Con - Tools für den täglichen Kampf als Entwickler
BED-Con - Tools für den täglichen Kampf als EntwicklerPatrick Baumgartner
 
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, Oehmichen
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, OehmichenJFS 2011 - Top 10 Tools & Methoden - Baumgartner, Oehmichen
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, OehmichenPatrick Baumgartner
 
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGi
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGiOSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGi
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGiPatrick Baumgartner
 
Pax – Tools für den OSGi Alltag
Pax – Tools für den OSGi AlltagPax – Tools für den OSGi Alltag
Pax – Tools für den OSGi AlltagPatrick Baumgartner
 

Más de Patrick Baumgartner (9)

Customer is king
Customer is kingCustomer is king
Customer is king
 
Daten natuerlich modellieren und verarbeiten mit Neo4j
Daten natuerlich modellieren und verarbeiten mit Neo4jDaten natuerlich modellieren und verarbeiten mit Neo4j
Daten natuerlich modellieren und verarbeiten mit Neo4j
 
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow Zurich
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow ZurichHow to use NoSQL in Enterprise Java Applications - NoSQL Roadshow Zurich
How to use NoSQL in Enterprise Java Applications - NoSQL Roadshow Zurich
 
BED-Con - Tools für den täglichen Kampf als Entwickler
BED-Con - Tools für den täglichen Kampf als EntwicklerBED-Con - Tools für den täglichen Kampf als Entwickler
BED-Con - Tools für den täglichen Kampf als Entwickler
 
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, Oehmichen
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, OehmichenJFS 2011 - Top 10 Tools & Methoden - Baumgartner, Oehmichen
JFS 2011 - Top 10 Tools & Methoden - Baumgartner, Oehmichen
 
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGi
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGiOSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGi
OSGi für Praktiker - Web Applikationen und verteilte Systeme mit OSGi
 
Pax – Tools für den OSGi Alltag
Pax – Tools für den OSGi AlltagPax – Tools für den OSGi Alltag
Pax – Tools für den OSGi Alltag
 
OSGi with the Spring Framework
OSGi with the Spring FrameworkOSGi with the Spring Framework
OSGi with the Spring Framework
 
Whats New In Spring 3.0 ?
Whats New In Spring 3.0 ?Whats New In Spring 3.0 ?
Whats New In Spring 3.0 ?
 

Último

The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfNeo4j
 
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...itnewsafrica
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Farhan Tariq
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observabilityitnewsafrica
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 

Último (20)

The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdf
 
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 

Neo4j Introduction (for Techies)

  • 1. Neo4j from the Command Line Perspective (Introduction) JUG MK | Skopje | 02.10.2013
  • 2. 2 Speaker Profile Patrick Baumgartner •  Senior Software Consultant | Partner @ Swiftmind •  Spring Framework, OSGi, Neo4j •  Spring Trainer, Neo4j Fanboy, Agilista •  Co-Author of „OSGi für Praktiker“ •  Co-Organizer of Neo4j Meetup Zurich •  @patbaumgartner
  • 3. 3 Swiftmind Your experts for Enterprise Java Areas of expertise •  Java EE •  Spring Framework •  OSGi •  Agile Methodologies •  Software Engineering Best Practices Headquarter •  Zürich, Schweiz •  @swiftmind •  http://www.swiftmind.com
  • 4. 4 Agenda •  Introduction to Graphs •  Use cases •  Neo4j •  Querying •  Import / Export •  Tools und APIs •  Polyglot Persistence •  Q & A
  • 5. 5 New Demands on Data Access •  Structured and unstructured data •  Massive amounts of data •  Inexpensive horizontal scaling •  Apps and data in the cloud •  Social network features •  …
  • 6. 6 New Types of Data Stores
  • 7. 7 NoSQL Data Volume Data Complexity Key-Value Stores Column Family Document Databases Graph Databases Relational Databases 90% of all use cases
  • 8. 8 Property Graph Model •  Graphs are made of –  Vertices / Nodes –  Edges / Relationships –  Properties Alice Bob Car name:Bob age:63 sex:male name:Alice age:21 sex:female type:car vendor:tesla type:OWNS type:DRIVES
  • 9. 9 Where is my graph? Use cases
  • 11. 11 Is it the only use case? Social Graph
  • 13. 13 Social & Spatial Data Alice Mat 5 Bob 13 8 ROAD ROAD LIKES KNOWS type:Hotel name:Radisson Blu lat:47.452549 long:8.564615
  • 19. 19 Neo4j – Big Picture •  Most used graph data base –  Robust & Mature: in production 24/7 since 2003 –  Community: Ecosystem with Tools, Bindings, Frameworks •  Licenses –  AGPLv3 Community Edition – OpenSource –  Advanced/Enterprise – for commercial applications •  Neo Technology –  Development & Support –  ~ 50 Persons / 6 Countries / 3 Continents
  • 20. 20 Features •  Object oriented, flexible network structure •  ACID transactions •  Horizontal scalable •  Java API –  Java, Groovy, Scala, JRuby •  Runtime –  Standalone Server –  Embedded Database •  Disk based storage manager •  Plugin and testing support
  • 21. 21 How do I find my data? Querying
  • 22. 22 Graph Querying •  How do I query the right nodes from the graph? –  Tell me all friends of friends of friends who liked the movie XYZ with more than 3 stars –  ... •  Querying methods –  Traversing with Neo4j API –  Traversal descriptions –  Graph algorithms –  Index queries –  Cypher queries
  • 23. 23 Neo4j API Node bob = ...; for ((Relationship rel: bob.getRelationships(RelTypes.KNOWS)) { Node friend = rel.getEndNode(); System.out.println(friend.getProperty("name")); } •  Simple, but very low level API •  To verbose for complex traversals
  • 24. 24 Traversal API •  Querying API for graphs •  Describes paths trough the graph •  Call back based •  Fluent API •  Several predefined constructs •  Neo4j implements the following graph algorithms: –  A* –  Dijkstra –  pathsWithLength –  shortestPath –  allSimplePaths –  allPaths
  • 25. 25 Traversal API – Constructs
  • 26. 26 Example: Traversal API TraversalDescription directFriends = Traversal.description() .breadthFirst() .relationships(RelTypes.KNOWS) .evaluator(Evaluators.toDepth(1)) .evaluator(Evaluators.excludeStartPosition()); for(Path p : directFriends.traverse(bob)) { System.out.println(p.endNode().getProperty(„firstname“)); }
  • 27. 27 Index Queries •  Support for node and relationship indices •  Lucene as default implementation node id property value 15 name Alice 15 yearOfBirth 1972 16 name Bob 46 name Carol 46 yearOfBirth 1983
  • 28. 28 Cypher Query Language •  Graph query language similar to SQL •  Declarative language •  Defines „What“ and not „How“ •  Uses pattern matching •  Support for –  Filters –  Pagination •  Supports CRUD functionality
  • 29. 29 Cypher Query Language – Elemente Element Description START Start element(s) (index- or id-lookup) MATCH Pattern to find nodes, describes paths (a) –[knows]-> (b) WHERE Result filter (boolean expression) SKIP LIMIT Pagination RETURN Defines return elements ORDER BY Sorting by properties PARAMETERS Parameter-Map, die im Cypher mittels Key oder Position verwendet werden kann CREATE Creates node nodes and relations SET Updates properties on nodes and relations DELETE Deletes unused nodes or relationships
  • 30. 30 Example: Cypher Query String query = "START person=node(12) “ + “MATCH person-[:KNOWS]-friend “ + “RETURN friend“; ExecutionEngine engine = new ExecutionEngine(graphDb); ExecutionResult result = engine.execute(query); Iterator<Object> column = result.columnAs("friend"); while(column.hasNext()) { Node friendNode = (Node)column.next(); System.out.println(friendNode.getProperty(PROP_FIRSTNAME)); } person friend KNOWS
  • 31. 31 Example: Cypher Create Query CREATE (carol {name:“Carol“}) return carol; +------------------------+ | carol | +------------------------+ | Node[1]{name:“carol“} | +------------------------+ START carol=node(1) CREATE (bob {name:“Bob"}), (bob)-[:knows]->(carol) return carol; START carol=node(1) CREATE (apple {name:“Apple“,type:“Fruit“}), (carol)-[:owns {number: 5}]->(apple); Carol Bob KNOWS Carol Carol Apple type: Fruit OWNS number: 5
  • 32. 32 Shipping data Import / Export – Node Manipulation
  • 33. 33 Node Creation with Java org.neo4j.graphdb.GraphDatabaseService graphDb = new GraphDatabaseFactory().newEmbeddedDatabase(DB_PATH); Transaction tx = graphDb.beginTx(); try { Node peter = createNode(graphDb, “Alice"); Node carol = createNode(graphDb, “Carol"); peter.createRelationshipTo(carol, RelTypes.KNOWS); .. tx.success(); } finally {tx.finish();} public Node createNode(GraphDatabaseService graphDb, String firstname) { Node person = graphDb.createNode(); person.setProperty(„firstname“, firstname); return person; } Alice Carol KNOWS
  • 35. 35 Spring Data Neo4j (SDN) •  POJOs mapped as nodes or relationships – type safe •  Works directly Database, typically embedded mode •  Data is fetched very fast and lazy •  Stores everything within a @Transaction •  Uses heavily AspectJ magic to enhance the POJOs •  …
  • 36. 36 Spring Data Neo4j – Entity _type_: com.example.Person name: "Alice" age: 42 @NodeEntity public class Person { private String name; private int age; // getters/setters… } Person alice = new Person(); alice.setName("Alice"); alice.setAge(42); alice.persist(); Node
  • 37. 37 Spring Data Neo4j – NodeEntity @NodeEntity public class Person { private String name; private int yearOfBirth; @RelatedTo(type = "KNOWS", direction = Direction.OUTGOING) private Set<Person> knownPersons; public void knows(Person p) { knownPersons.add(p); } public Set<Person> getFriends() { return knownPersons; } } Person alice = ...; alice.knows(bob); alice.knows(carol); Alice Bob KNOWS Carol KNOWS
  • 38. 38 Spring Data Neo4j – Relationship @RelationshipEntity public class Knows { private int sinceYear; public Knows since(int year) { this.sinceYear = year; return this; } } @NodeEntity public class Person { public Known knows(Person p) { return this.relateTo(p, Knows.class, "KNOWS"); } } Person alice = ...; Person bob ...; alice.knows(bob).since(2012); Alice Bob KNOWS since: 2012
  • 39. 39 Spring Data Neo4j – Repository public interface PersonRepository extends GraphRepository<Person> { @Query("start person = {0} match ... return ...") Iterable<Product> getOwnedServices(Person person); Iterable<Person> findByName(String name); Iterable<Person> findByNameLike(String name); } @Autowired PersonRepository personRepository; Person alice = personRepository.findByName("Alice");
  • 40. 40 Thinkerpop Blueprint Thinkerpop Blueprint Extensions •  GraphML Reader/Writer Library •  GraphSon Reader/Writer Library •  GML Reader/Writer Library •  Java Universal Network/ Graph Framework
  • 41. 41 GraphML •  GraphML (http://graphml.graphdrawing.org/ ) –  Standardized format –  Tool support –  Pure and simple XML <graph id="G" edgedefault="directed"> <node id="n0"/> <node id="n1"/> <edge source="n0" target="n1"/> </graph>
  • 42. 42 Neo4j Tools •  GraphML –  Gremlin Plugin (no further development) –  Thinkerpop Blueprint Extensions •  CSV –  BatchInserter –  ParallelBatchInserter
  • 43. 43 Useful tools for your daily work Tools & APIs
  • 44. 44 Tools & APIs (2) •  Web console –  Data overview –  Querying and visual graph presentation –  „Command line“ •  Neo4j Shell –  Command line –  Sends UNIX-like Commands via RMI (cd, ls, pwd) –  Cypher Queries Support •  REST API –  JSON –  Clients for Java, .NET, PHP, Ruby, … •  Neoclipse –  Visual presentation of the graph –  Filter options for partial graph presentation
  • 45. 45 What?! Your app uses only one DB? Polyglot Persistence
  • 46. 46 Polyglot Persistence Web shop application User Sessions Shopping Cart Recommendations Product Catalog Analytics Financial Data Redis Riak Neo4j MongoDB Casandra MySQL
  • 49. 49 Thank you! Patrick Baumgartner, @patbaumgartner patrick.baumgartner [at] swiftmind [dot] com http://www.swiftmind.com @swiftmind