"Dove sono i tuoi vertici e di cosa stanno parlando?" by Roberto Franchini
OrientDB unisce la potenza di un database a grafo con la flessibilità di un document database creando il primo database multi-modello. Il talk esplora le funzionalità avanzate di ricerca geo-spaziale e full-text di OrientDB basate su Lucene. I due modelli di interrogazione, completamente integrati nel linguaggio SQL di OrientDB, aprono possibilità di analisi avanzate per dati geolocalizzati e testi non strutturati.
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
Dove sono i tuoi vertici e di cosa stanno parlando?
1. Roberto Franchini - OrientDB
ROME 18-19 MARCH 2016
Where are your vertexes
and what are they talking
about?
2. whoami(1)
More than 15 years of experience, proud to be a
programmer
Member of OrientDB team, tech lead for full-text
& spatial indexes, JDBC driver and Docker
images
Wrote software for NLP and opinion mining on
fast data/big data
JUG-Torino co-lead
12. Vertices and Edges
can have properties
Vertices are directed
* https://github.com/tinkerpop/blueprints/wiki/Property-Graph-Model
Property Graph Model*
Rome
country: Italy
Roberto
company: OrientDB
Vertices and Edges
can have properties
Vertices and Edges
can have properties
Visited
on: 2016
13. Roberto
Rome
Visited
on: 2016
An Edge connects only 2 vertices
Use multiple edges to represent
1-N and N-M relationships
Worked
on: 2016
1-N and N-M relationships
14. Rob Rome
Visited
on: 2016
#13:55 #15:99
out = #22:11
in = #22:11
#22:11
(Edge)
(Vertex) (Vertex)
out = #13:55
in = #15:99
Connections use
persistent
pointers
Each element in the
Graph has own
immutable Record ID
Each element in the
Graph has own
immutable Record ID
Each element in the
Graph has own
immutable Record ID
18. GraphDocument
Object
Key/
Value
Multi Model represents the
intersection
of multiple models in just one
product
- Just one product to learn and maintain
- Just one vendor relationship to manage
- No ETL, no synchronization required
- Performance and Reliability is easy to test from the
beginning
Multi-model
22. Index
A Vertex is just a Document
We can define indexes on fields
CREATE CLASS User EXTENDS V
CREATE PROPERTY User.userId LONG
CREATE INDEX User.userId ON User(userId) UNIQUE
SELECT FROM User WHERE userId = 1024
23. What?
Ok, but my Users can describe themselves with
free text. How can I find users describing
themselves as programmes?
CREATE PROPERTY User.description STRING
CREATE INDEX User.description
ON User(description) FULLTEXT ENGINE LUCENE
SELECT FROM User
WHERE description LUCENE “programmer”
24. From where?
Users write articles with geo localisation data
inside. I want all the article posted from the Rome
area
CREATE CLASS Article EXTENDS V
CREATE PROPERTY Article.geo EMBEDDED OPoint
CREATE INDEX Article.geo
ON Article (geo) SPATIAL ENGINE LUCENE
SELECT * FROM Article
WHERE ST_WITHIN(geo,
ST_Buffer(
ST_GeomFromText(‘POINT(12.5113300 41.8919300)'),
1)) = true
27. User schema
CREATE CLASS User EXTENDS V
CREATE PROPERTY User.userId LONG
CREATE INDEX User.userId ON User(userId) UNIQUE
CREATE PROPERTY User.description STRING
CREATE PROPERTY User.screenName STRING
CREATE PROPERTY User.lang STRING
CREATE PROPERTY User.location STRING
28. Tweet schema
CREATE CLASS Tweet EXTENDS V
CREATE PROPERTY Tweet.tweetId LONG
CREATE INDEX Tweet.tweetId ON Tweet(tweetId) UNIQUE
CREATE PROPERTY Tweet.text STRING
CREATE PROPERTY Tweet.lang STRING
CREATE PROPERTY Tweet.location STRING
CREATE PROPERTY Tweet.createdAt DATETIME
CREATE PROPERTY Tweet.isRetweeted BOOLEAN
CREATE PROPERTY Tweet.isRetweet BOOLEAN
29. Indexes
CREATE INDEX User.description ON User(description)
FULLTEXT ENGINE LUCENE
CREATE INDEX Tweet.text ON Tweet(text)
FULLTEXT ENGINE LUCENE
CREATE PROPERTY Tweet.geo EMBEDDED OPoint
CREATE INDEX Tweet.geo ON Tweet (geo)
SPATIAL ENGINE LUCENE
30. Relations
CREATE CLASS Posts EXTENDS E
CREATE CLASS Hashtag EXTENDS V
CREATE PROPERTY Hashtag.label STRING
CREATE CLASS Tags EXTENDS E
CREATE CLASS Source EXTENDS V
CREATE PROPERTY Source.name STRING
CREATE CLASS Using EXTENDS E
CREATE CLASS Follows EXTENDS E
CREATE CLASS Retweets EXTENDS E
CREATE CLASS ReplyTo EXTENDS E
CREATE CLASS Mentions EXTENDS E
33. OrientDB Features
First Multi-Model DBMS with a Graph-Engine
Open Source Apache2 license
Data Models are built into the core engine
The Graph Database engine allows O(1)
performance on traversing relationships, against
O(LogN) of RDBMS and any other Multi-Model
DBMS built as layers
34. APIs and tools
Support for TinkerPop standard for Graph DB:
Gremlin language and Blueprints API
SQL + extensions for graphs
Live Query
FullText indexing based on Lucene
Spatial indexing (points and polygons)
35. APIs and tools
JDBC driver to connect any BI tool
HTTP/JSON support
ETL tool
Teleporter (EE, import from RDBMS)
Drivers in Java, Node.js, Python, PHP, .NET, Perl, C/
C++ and more
36. Get Started for Free
OrientDB Community Edition is FREE
for any purpose (Apache 2 license)
Udemy Getting Started Training is
and Free
http://www.orientechnologies.com/getting-started
OrientDB Enterprise is Free for
Development
37. OrientDB At a Glance
70,000
Downloads per month
from 200+ countries
100+
Code contributors on
Github and 15,000+
commits
1,000s
Users from SMBs to
Fortune 10 Companies
17+
Years of Product
Research
Global Coverage and 24x7 Support
38. Thanks!
ROME 18-19 MARCH 2016
http://www.orientdb.com
@robfrankie
r.franchini@orientdb.com
All pictures belong
to their respective authors