A presentation of the Neo4j graph database given at QCon SF 2008. It describes why relational databases are increasingly unfit for many applications today and why graphs may be a good fit. It also covers the fundamentals of how to program with Neo4j.
Emil Eifrem, the CEO, founder and developer of neo4j in Mumbai at Directi giving a talk on NoSQL databases (his area of expertise) where he covers various NoSQL databases and then spends a bulk of time on neo4j.
In the Telecommunications sector, there are a lot of complex data sets and problems that are well suited for graph models and the use of graph databases like Neo4j.
This talk gives just some ideas on where Neo4j currently is used within the TelCo sector. If you recognize problem areas that you have, don't hesitate to contact me at peter at neotechnology dot com, we are eager to learn more and help!
Emil Eifrem, the CEO, founder and developer of neo4j in Mumbai at Directi giving a talk on NoSQL databases (his area of expertise) where he covers various NoSQL databases and then spends a bulk of time on neo4j.
In the Telecommunications sector, there are a lot of complex data sets and problems that are well suited for graph models and the use of graph databases like Neo4j.
This talk gives just some ideas on where Neo4j currently is used within the TelCo sector. If you recognize problem areas that you have, don't hesitate to contact me at peter at neotechnology dot com, we are eager to learn more and help!
A NOSQL Overview And The Benefits Of Graph Databases (nosql east 2009)Emil Eifrem
Presentation given at nosql east 2009 in Atlanta. Introduces the NOSQL space by offering a framework for categorization and discusses the benefits of graph databases. Oh, and also includes some tongue-in-cheek party poopers about sucky things in the NOSQL space.
The Data2Semantics project (COMMIT P23) is all about enriching research data, and making it more reusable for future research. Using Linked Data for this task is a fairly obvious step to make (surprise!). However, there are several shortcomings the current practices in publishing Linked Data, that calls for a slightly
different approach which (hopefully) bridges a gap between Web 2.0 and Web 3.0. I will present a proof-of-concept service (Linkitup) that works on top of existing scientific data repositories, and allows individual researchers to enrich their data with additional (linked) metadata.
API's, Freebase, and the Collaborative Semantic webDan Delany
A presentation about the state of the collaborative semantic web, including:
- What?
- Why?
- Where do we stand?
- A case study on Metaweb's Freebase project
Querying Riak Just Got Easier - Introducing Secondary IndicesRusty Klophaus
This presentation introduces new Riak KV functionality called Secondary Indexes. Secondary Indices allows a developer to retrieve data by attribute value, rather than by primary key.
Currently, a developer coding outside of Riak’s key/value based access must maintain their own indexes into the data using links, other Riak objects, or external systems. This is straightforward for simple use cases, but can add substantial coding and data modeling for complex applications. By formalizing an approach and building index support directly into Riak KV, we remove this burden from the application developer while preserving Riak’s core benefits, including scalability and tolerance against hardware failure and network partitions.
The presentation covers usage, capabilities, limitations, and lessons learned.
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007Marc Smith
Overview of the NodeXL project (Network Overview, Discovery and Exploration) that adds social network metrics and visualization features to Excel 2007. Contains updated images from version .84 of the NodeXL project.
Building Large-scale Real-world Recommender Systems - Recsys2012 tutorialXavier Amatriain
There is more to recommendation algorithms than rating prediction. And, there is more to recommender systems than algorithms. In this tutorial, given at the 2012 ACM Recommender Systems Conference in Dublin, I review things such as different interaction and user feedback mechanisms, offline experimentation and AB testing, or software architectures for Recommender Systems.
SemSearch09 workshop at WWW2009, April 21th 2009- http://km.aifb.uni-karlsruhe.de/ws/semsearch09/ - Paper available at: http://km.aifb.uni-karlsruhe.de/ws/semsearch09/semse2009_25.pdf
Building RESTful Java Applications with EMFKenn Hussey
Representational State Transfer (REST) is a style of software architecture for distributed hypermedia systems such as the World Wide Web. However, it is possible to design any enterprise software system in accordance with the REST architectural style without using the HTTP protocol and without interacting with the World Wide Web.
Systems that follow the principles of REST often referred to as RESTful. Proponents of REST argue that the Web enjoyed the scalability and growth that it has had as a direct result of a few key design principles. Among these principles are the notions that application state and functionality are divided into resources and that every resource is uniquely addressable using a universal syntax for use in hypermedia links. Another key principle of REST is that all resources share a uniform interface for the transfer of state between client and resource, consisting of a constrained set of content types and a constrained set of well-defined operations.
The Eclipse Modeling Framework (EMF) provides a Java runtime framework and tools for generative application development and fine-grained data integration based on simple models. Models can be specified directly using EMF's metamodel, Ecore, or imported from other forms, including UML and XML Schema. Given a model specification, EMF can generate a corresponding set of Java interfaces and implementation classes that can easily be mixed with hand-written code for maximum flexibility. When deployed, applications developed with EMF benefit from a powerful and extensible runtime, which, among other features, includes a persistence mechanism which has always supported the principles of REST – perhaps even before the term "REST" became popular. This tutorial will provide an introduction to EMF, including alternatives for specifying a model, EMF's code generation tools, and key runtime framework concepts. As a practical usage of this knowledge, the presenters will show how EMF can be used to build RESTful applications, exploring some best practices for working with resources and other features of the framework.
Academic presentation about the Relational Cloud system based on the paper "Relational Cloud: A Database-as-a-Service for the Cloud" by Carlo Curino et al.
Startups in Sweden vs Startups in Silicon Valley, 2015 editionEmil Eifrem
Differences between running a startup in Sweden and a startup in Silicon Valley. Bonus: How Neo Technology (Neo4j) uses aspects of Scandinavian culture as a competitive advantage. Presented at the Nordic themed Monki Gräs in London, Jan of 2015.
Btw, we at Neo4j are hiring: http://neo4j.com/jobs/ :)
A NOSQL Overview And The Benefits Of Graph Databases (nosql east 2009)Emil Eifrem
Presentation given at nosql east 2009 in Atlanta. Introduces the NOSQL space by offering a framework for categorization and discusses the benefits of graph databases. Oh, and also includes some tongue-in-cheek party poopers about sucky things in the NOSQL space.
The Data2Semantics project (COMMIT P23) is all about enriching research data, and making it more reusable for future research. Using Linked Data for this task is a fairly obvious step to make (surprise!). However, there are several shortcomings the current practices in publishing Linked Data, that calls for a slightly
different approach which (hopefully) bridges a gap between Web 2.0 and Web 3.0. I will present a proof-of-concept service (Linkitup) that works on top of existing scientific data repositories, and allows individual researchers to enrich their data with additional (linked) metadata.
API's, Freebase, and the Collaborative Semantic webDan Delany
A presentation about the state of the collaborative semantic web, including:
- What?
- Why?
- Where do we stand?
- A case study on Metaweb's Freebase project
Querying Riak Just Got Easier - Introducing Secondary IndicesRusty Klophaus
This presentation introduces new Riak KV functionality called Secondary Indexes. Secondary Indices allows a developer to retrieve data by attribute value, rather than by primary key.
Currently, a developer coding outside of Riak’s key/value based access must maintain their own indexes into the data using links, other Riak objects, or external systems. This is straightforward for simple use cases, but can add substantial coding and data modeling for complex applications. By formalizing an approach and building index support directly into Riak KV, we remove this burden from the application developer while preserving Riak’s core benefits, including scalability and tolerance against hardware failure and network partitions.
The presentation covers usage, capabilities, limitations, and lessons learned.
2009 - Node XL v.84+ - Social Media Network Visualization Tools For Excel 2007Marc Smith
Overview of the NodeXL project (Network Overview, Discovery and Exploration) that adds social network metrics and visualization features to Excel 2007. Contains updated images from version .84 of the NodeXL project.
Building Large-scale Real-world Recommender Systems - Recsys2012 tutorialXavier Amatriain
There is more to recommendation algorithms than rating prediction. And, there is more to recommender systems than algorithms. In this tutorial, given at the 2012 ACM Recommender Systems Conference in Dublin, I review things such as different interaction and user feedback mechanisms, offline experimentation and AB testing, or software architectures for Recommender Systems.
SemSearch09 workshop at WWW2009, April 21th 2009- http://km.aifb.uni-karlsruhe.de/ws/semsearch09/ - Paper available at: http://km.aifb.uni-karlsruhe.de/ws/semsearch09/semse2009_25.pdf
Building RESTful Java Applications with EMFKenn Hussey
Representational State Transfer (REST) is a style of software architecture for distributed hypermedia systems such as the World Wide Web. However, it is possible to design any enterprise software system in accordance with the REST architectural style without using the HTTP protocol and without interacting with the World Wide Web.
Systems that follow the principles of REST often referred to as RESTful. Proponents of REST argue that the Web enjoyed the scalability and growth that it has had as a direct result of a few key design principles. Among these principles are the notions that application state and functionality are divided into resources and that every resource is uniquely addressable using a universal syntax for use in hypermedia links. Another key principle of REST is that all resources share a uniform interface for the transfer of state between client and resource, consisting of a constrained set of content types and a constrained set of well-defined operations.
The Eclipse Modeling Framework (EMF) provides a Java runtime framework and tools for generative application development and fine-grained data integration based on simple models. Models can be specified directly using EMF's metamodel, Ecore, or imported from other forms, including UML and XML Schema. Given a model specification, EMF can generate a corresponding set of Java interfaces and implementation classes that can easily be mixed with hand-written code for maximum flexibility. When deployed, applications developed with EMF benefit from a powerful and extensible runtime, which, among other features, includes a persistence mechanism which has always supported the principles of REST – perhaps even before the term "REST" became popular. This tutorial will provide an introduction to EMF, including alternatives for specifying a model, EMF's code generation tools, and key runtime framework concepts. As a practical usage of this knowledge, the presenters will show how EMF can be used to build RESTful applications, exploring some best practices for working with resources and other features of the framework.
Academic presentation about the Relational Cloud system based on the paper "Relational Cloud: A Database-as-a-Service for the Cloud" by Carlo Curino et al.
Startups in Sweden vs Startups in Silicon Valley, 2015 editionEmil Eifrem
Differences between running a startup in Sweden and a startup in Silicon Valley. Bonus: How Neo Technology (Neo4j) uses aspects of Scandinavian culture as a competitive advantage. Presented at the Nordic themed Monki Gräs in London, Jan of 2015.
Btw, we at Neo4j are hiring: http://neo4j.com/jobs/ :)
An Overview of the Emerging Graph Landscape (Oct 2013)Emil Eifrem
Recent years have seen an explosion of technologies for managing, processing and analyzing graphs, ranging from community projects like Apache Giraph, to vendor led products such as Neo4j and spin outs from established companies like Twitter’s FlockDB. The sheer number of technologies makes it difficult to keep track of these tools and what sets them apart, even for those of us who are active in the space!
But all graph technologies are not created equal. This session will provide a high level framework for making sense of the emerging graph landscape. It will describe the three dominant graph data models today, define top level categories like graph compute engines (Graphlab, Giraph, Pegasus, YarcData, etc) and graph databases (Neo4j, FlockDB, OrientDB, etc) and discuss common characteristics and important properties of each category.
Startups in Sweden vs Startups in Silicon ValleyEmil Eifrem
Differences between running a startup in Sweden and a startup in Silicon Valley. Presented at Stanford's "European Entrepreneurship & Innovation" (http://www.europeanentrepreneursatstanford.com) in Jan of 2012.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
"Impact of front-end architecture on development cost", Viktor TurskyiFwdays
I have heard many times that architecture is not important for the front-end. Also, many times I have seen how developers implement features on the front-end just following the standard rules for a framework and think that this is enough to successfully launch the project, and then the project fails. How to prevent this and what approach to choose? I have launched dozens of complex projects and during the talk we will analyze which approaches have worked for me and which have not.
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Accelerate your Kubernetes clusters with Varnish CachingThijs Feryn
A presentation about the usage and availability of Varnish on Kubernetes. This talk explores the capabilities of Varnish caching and shows how to use the Varnish Helm chart to deploy it to Kubernetes.
This presentation was delivered at K8SUG Singapore. See https://feryn.eu/presentations/accelerate-your-kubernetes-clusters-with-varnish-caching-k8sug-singapore-28-2024 for more details.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Let's dive deeper into the world of ODC! Ricardo Alves (OutSystems) will join us to tell all about the new Data Fabric. After that, Sezen de Bruijn (OutSystems) will get into the details on how to best design a sturdy architecture within ODC.
4. Trend 1: data is getting more connected
Giant
Global
Information connectivity
Graph
(GGG)
Ontologies
RDF
Folksonomies
Tagging
User-
Wikis
generated
content
Blogs
RSS
Hypertext
Text
documents web 1.0 web 2.0 “web 3.0”
1990 2000 2010 2020
5. Trend 2: ... and more semi-structured
Individualization of content!
In the salary lists of the 1970s, all elements had
exactly one job
In the salary lists of the 2000s, we need 5 job
columns! Or 8? Or 15?
Trend accelerated by the decentralization of
content generation that is the hallmark of the age
of participation (“web 2.0”)
6. Relational database
Salary List
Performance
Majority of
Webapps
Social network
Semantic
}
Trading
custom
Information complexity
10. A graph
A simple food web
(image from vtaide.com)
11. A big graph
Part of the food
web of the North
Atlantic (image from jeffkenedyassociates.com)
12. A social graph
LinkedIn
Facebook
Orkut
Hi5
Friendster
Dopplr
...
13. Your file system
Files & folders
Alias, links
Read & write
Roles, groups
...
14. Shut up and
show us the
code!
Image credit: lost! (please don’t shoot me)
15. The Graph DB model: representation
Core abstractions: name = “Emil”
age = 29
Nodes sex = “yes”
Relationships between nodes
1 2
Properties on both
type = KNOWS
time = 4 years 3
type = car
vendor = “SAAB”
model = “95 Aero”
16. Example: The Matrix
name = “The Architect”
name = “Morpheus”
rank = “Captain”
name = “Thomas Anderson”
occupation = “Total badass” 42
age = 29
disclosure = public
KNOWS KNOWS CODED_BY
1 KN O
7 3 WS
13
S
KN name = “Cypher”
KNOW
OW last name = “Reagan”
S
name = “Agent Smith”
disclosure = secret version = 1.0b
age = 3 days age = 6 months language = C++
2
name = “Trinity”
17. Code (1): Building a node space
NeoService neo = ... // Get factory
// Create Thomas 'Neo' Anderson
Node mrAnderson = neo.createNode();
mrAnderson.setProperty( quot;namequot;, quot;Thomas Andersonquot; );
mrAnderson.setProperty( quot;agequot;, 29 );
// Create Morpheus
Node morpheus = neo.createNode();
morpheus.setProperty( quot;namequot;, quot;Morpheusquot; );
morpheus.setProperty( quot;rankquot;, quot;Captainquot; );
morpheus.setProperty( quot;occupationquot;, quot;Total bad assquot; );
// Create a relationship representing that they know each other
mrAnderson.createRelationshipTo( morpheus, RelTypes.KNOWS );
// ...create Trinity, Cypher, Agent Smith, Architect similarly
18. Code (1): Building a node space
NeoService neo = ... // Get factory
Transaction tx = neo.begin();
// Create Thomas 'Neo' Anderson
Node mrAnderson = neo.createNode();
mrAnderson.setProperty( quot;namequot;, quot;Thomas Andersonquot; );
mrAnderson.setProperty( quot;agequot;, 29 );
// Create Morpheus
Node morpheus = neo.createNode();
morpheus.setProperty( quot;namequot;, quot;Morpheusquot; );
morpheus.setProperty( quot;rankquot;, quot;Captainquot; );
morpheus.setProperty( quot;occupationquot;, quot;Total bad assquot; );
// Create a relationship representing that they know each other
mrAnderson.createRelationshipTo( morpheus, RelTypes.KNOWS );
// ...create Trinity, Cypher, Agent Smith, Architect similarly
tx.commit();
19. Code (1b): Defining RelationshipTypes
// In package org.neo4j.api.core
public interface RelationshipType
{
String name();
}
// In package org.yourdomain.yourapp
// Example on how to roll dynamic RelationshipTypes
class MyDynamicRelType implements RelationshipType
{
private final String name;
MyDynamicRelType( String name ){ this.name = name; }
public String name() { return this.name; }
}
// Example on how to kick it, static-RelationshipType-like
enum MyStaticRelTypes implements RelationshipType
{
KNOWS,
WORKS_FOR,
}
20. The Graph DB model: traversal
Traverser framework for name = “Emil”
high-performance traversing age = 29
sex = “yes”
across the node space
1 2
type = KNOWS
time = 4 years 3
type = car
vendor = “SAAB”
model = “95 Aero”
21. Example: Mr Anderson’s friends
name = “The Architect”
name = “Morpheus”
rank = “Captain”
name = “Thomas Anderson”
occupation = “Total badass” 42
age = 29
disclosure = public
KNOWS KNOWS CODED_BY
1 KN O
7 3 WS
13
S
KN name = “Cypher”
KNOW
OW last name = “Reagan”
S
name = “Agent Smith”
disclosure = secret version = 1.0b
age = 3 days age = 6 months language = C++
2
name = “Trinity”
22. Code (2): Traversing a node space
// Instantiate a traverser that returns Mr Anderson's friends
Traverser friendsTraverser = mrAnderson.traverse(
Traverser.Order.BREADTH_FIRST,
StopEvaluator.END_OF_GRAPH,
ReturnableEvaluator.ALL_BUT_START_NODE,
RelTypes.KNOWS,
Direction.OUTGOING );
// Traverse the node space and print out the result
System.out.println( quot;Mr Anderson's friends:quot; );
for ( Node friend : friendsTraverser )
{
System.out.printf( quot;At depth %d => %s%nquot;,
friendsTraverser.currentPosition().getDepth(),
friend.getProperty( quot;namequot; ) );
}
23. name = “The Architect”
name = “Morpheus”
rank = “Captain”
name = “Thomas Anderson”
occupation = “Total badass” 42
age = 29
disclosure = public
KNOWS KNOWS CODED_BY
1 KN O
7 3 WS
13
S
KN name = “Cypher”
KNOW
OW last name = “Reagan”
S
name = “Agent Smith”
disclosure = secret version = 1.0b
age = 3 days age = 6 months language = C++
2
name = “Trinity”
$ bin/start-neo-example
Mr Anderson's friends:
At depth 1 => Morpheus
friendsTraverser = mrAnderson.traverse(
Traverser.Order.BREADTH_FIRST, At depth 1 => Trinity
StopEvaluator.END_OF_GRAPH, At depth 2 => Cypher
ReturnableEvaluator.ALL_BUT_START_NODE,
RelTypes.KNOWS,
At depth 3 => Agent Smith
Direction.OUTGOING ); $
24. Example: Friends in love?
name = “The Architect”
name = “Morpheus”
rank = “Captain”
name = “Thomas Anderson”
occupation = “Total badass” 42
age = 29
disclosure = public
KNOWS KNOWS CODED_BY
1 7 3 KN O
WS
13
S
KN
KNOW
name = “Cypher”
OW last name = “Reagan”
S
name = “Agent Smith”
LO disclosure = secret version = 1.0b
VE age = 6 months language = C++
S
2
name = “Trinity”
25. Code (3a): Custom traverser
// Create a traverser that returns all “friends in love”
Traverser loveTraverser = mrAnderson.traverse(
Traverser.Order.BREADTH_FIRST,
StopEvaluator.END_OF_GRAPH,
new ReturnableEvaluator()
{
public boolean isReturnableNode( TraversalPosition pos )
{
return pos.currentNode().hasRelationship(
RelTypes.LOVES, Direction.OUTGOING );
}
},
RelTypes.KNOWS,
Direction.OUTGOING );
26. Code (3a): Custom traverser
// Traverse the node space and print out the result
System.out.println( quot;Who’s a lover?quot; );
for ( Node person : loveTraverser )
{
System.out.printf( quot;At depth %d => %s%nquot;,
loveTraverser.currentPosition().getDepth(),
person.getProperty( quot;namequot; ) );
}
27. name = “The Architect”
name = “Morpheus”
rank = “Captain”
name = “Thomas Anderson”
occupation = “Total badass” 42
age = 29
disclosure = public
KNOWS KNOWS KN O CODED_BY
1 7 3 WS
13
S
KN
KNOW
name = “Cypher”
OW last name = “Reagan”
S
name = “Agent Smith”
LO disclosure = secret version = 1.0b
VE age = 6 months language = C++
S 2
name = “Trinity”
$ bin/start-neo-example
new ReturnableEvaluator()
Who’s a lover?
{
public boolean isReturnableNode(
TraversalPosition pos)
At depth 1 => Trinity
{ $
return pos.currentNode().
hasRelationship( RelTypes.LOVES,
Direction.OUTGOING );
}
},
28. Bonus code: domain model
How do you implement your domain model?
Use the delegator pattern, i.e. every domain entity
wraps a Neo4j primitive:
// In package org.yourdomain.yourapp
class PersonImpl implements Person
{
private final Node underlyingNode;
PersonImpl( Node node ){ this.underlyingNode = node; }
public String getName()
{
return this.underlyingNode.getProperty( quot;namequot; );
}
public void setName( String name )
{
this.underlyingNode.setProperty( quot;namequot;, name );
}
}
29. Domain layer frameworks
Qi4j (www.qi4j.org)
Framework for doing DDD in pure Java5
Defines Entities / Associations / Properties
Sound familiar? Nodes / Rel’s / Properties!
Neo4j is an “EntityStore” backend
NeoWeaver (http://components.neo4j.org/neo-weaver)
Weaves Neo4j-backed persistence into domain
objects in runtime (dynamic proxy / cglib based)
Veeeery alpha, but veeery cool
30. Neo4j system characteristics
Disk-based
Native graph storage engine with custom (“SSD-
ready”) binary on-disk format
Transactional
JTA/JTS, XA, 2PC, Tx recovery, deadlock
detection, etc
Scalable
Several billions of nodes/rels/props on single JVM
Robust
5+ years in 24/7 production
31. Social network pathExists()
12
~1k persons
3
7 1 Avg 50 friends per
person
pathExists(a, b) limit
36
41 77 depth 4
5
Two backends
Eliminate disk IO so
warm up caches
32. Social network pathExists()
2
Emil
1 5
7
Mike Kevin
3 John
Marcus
9 4
Bruce Leigh
# persons query time
Relational database (MySQL) 1 000 2 000 ms
Graph database (Neo4j) 1 000 2 ms
Graph database (Neo4j) 1 000 000 2 ms
33. Pros & Cons compared to RDBMS
+ No O/R impedance mismatch (whiteboard friendly)
+ Can easily evolve schemas
+ Can represent semi-structured info
+ Can represent graphs/networks (with performance)
- Lacks in tool and framework support
- No other implementations => potential lock in
- No support for ad-hoc queries
+
34. More consequences
Ability to capture semi-structured information
=> allowing individualization of content
No predefined schema
=> easier to evolve model
=> can capture ad-hoc relationships
Can capture non-normative relations
=> easy to model specific links to specific sets
All state is kept in transactional memory
=> improves application concurrency
35. The Neo4j ecosystem
Neo4j is an embedded database
Tiny teeny lil jar file
Component ecosystem
index-util
neo-meta
neo-utils
owl2neo
sparql-engine
...
See http://components.neo4j.org
36. Example: NeoRDF
NeoRDF triple/quad store
OWL SPARQL
RDF
Metamodel Graph
match
Neo4j
37. Future development
Productify RDF support (Neo4j 1.1)
Tool support (Neo4j 1.1 and onwards)
Language bindings
Currently Jython, Python, Ruby
Probably works well with Groovy, Beanshell, etc
Tomorrow Scala? .NET? Erlang?
Standalone server
Experimental RemoteNeo in laboratory right now
How standardize REST API? SPARQL protocol?
38. Future development
Distribution (Neo4j 2.0), current thoughts:
Best bet today: sharding on top of
(Infiniflow) from Paremus: www.codecauldron.org
Fundamentals:
CAP theorem
BASE (“ACID 2.0”)
Eventual consistency
Separate HA and data partitioning
Generic clustering algorithm as base case, but
give lots of knobs for developers
39. How ego are you? (aka other impls?)
Franz’ AllegroGraph (http://agraph.franz.com)
Proprietary, Lisp, RDF-oriented but real graphdb
FreeBase graphd (http://blog.freebase.com/2008/04/09/a-
brief-tour-of-graphd/)
In-house at Metaweb
Kloudshare (http://whydoeseverythingsuck.com)
Graph database in the cloud, still stealth mode
Some academic papers from ~10 years ago
G = {V, E}
40. Conclusion
Graphs && Neo4j => teh awesome!
Available NOW under AGPLv3 / commercial license
AGPLv3: “if you’re open source, we’re open source”
If you have proprietary software? Must buy a
commercial license
But up to 1M primitives it’s free for all uses!
Download
http://neo4j.org
Feedback
http://lists.neo4j.org
43. Neo4j architecture gotchas
Focus on the domain (whiteboard friendly –
domain-first development)
Purpose of the domain layer:
“an adaptation of the generic node space to a
type-safe, object-oriented abstraction expressed
in the vocabulary of our domain” (!)
Implementation mindset
Assume the node space is always in memory
Assume everything is automatically persistent
Focus on logical transactions instead of artificial
load/stores
44. Implementation pointers
Use the delegator pattern, i.e. every domain entity
wraps a Neo4j primitive as follows:
Actor actor = new ActorImpl( underlyingNode );
Remember that the wrappers are extremely
lightweight – they contain no state except for a
reference – so create them freely!
It is good practice to override equals/hashCode
Delegate to underlying{Node,Relationship}’s
equals() or hashCode() implementation