Más contenido relacionado
La actualidad más candente (20)
Similar a Intoduction to OrientDB (20)
Intoduction to OrientDB
- 2. Page
Relational database
/ Copyright ©2014 by Readify Limited2
› Data is presented to the user in the form of rows
and columns (a relation)
› Data can be manipulated through relational
operators in a tabular form
- 3. Page
Over Time
/ Copyright ©2014 by Readify Limited3
› Data start grown in size
› Data become heterogonous
› Structured, semi-structured, unstructured
- 5. Page
Relational database low
/ Copyright ©2014 by Readify Limited5
If the only tool you have is a relational database,
everything looks like a table.
- 6. Page
One tool doesn’t fit all
› Scalability issues
› Scale out
› Index intensive issues
› Join data
/ Copyright ©2014 by Readify Limited6
- 7. Page
Issues with joins
› the relationships are computed every time a
query is performed
› time complexity grows with data: O(log n)
› heavy runtime cost with large datasets
› Index lookup does not help, it could speeds up
searches but slows down inserts, updates,
deletes. Imagine on billions of records.
/ Copyright ©2014 by Readify Limited7
- 8. Page
NoSQL movement
/ Copyright ©2014 by Readify Limited8
› Not only SQL
› Simplicity of design (through different data
models)
› Being non-relational
› Simpler horizontal scaling
› Distributed
- 9. Page
NoSQL Models
› Document
› MongoDB, CouchDB, ….
› Key-value
› Cassandra, Redis, …
› Column
› Hbase, Cassandra, ..
› Graph
› Neo4j, ..
/ Copyright ©2014 by Readify Limited9
- 11. Page
NoSQL one model limitations
› Document model: no relationships, no schema
validation
› Graph model: no complex data, no schema
› key-value model: faster, but-key based access
only
› no transactions
/ Copyright ©2014 by Readify Limited11
- 15. Page
Why OrientDB
/ Copyright ©2014 by Readify Limited15
› Native document store (schema-free, complex properties)
› Native graph store (index-free adjacent, fast relationships
traversal)
› Object oriented concepts (classes, inheritance, polymorphism)
› ACID Transactions (no lock applied but at commit time, the
MVCC applied)
› Rest / JSON interface
› Distributed (multi-master replication / sharding)
› SQL (extended)
- 18. Page
Graph
/ Copyright ©2014 by Readify Limited18
drives
name: Abdo
Vertices can
have
properties
Vertices are
directed
AudiAbdo
license: A134
model: Q7
doors: 5Edges can
have
properties
- 19. Page
Abdo Lyon
An Edge connects only 2 vertices
Use multiple edges to represent 1-N
and N-M relationships
1-N and N-M Relationships
Graph
- 20. Page
Basic Concepts
› Class
› Used to represent type of data model
› Cluster
› Stores group of records within a class
/ Copyright ©2014 by Readify Limited20
Class Car
Cluster
USA_Car
Cluster
Germany_Car
- 21. Page
Vertices
› Record Identifier (RID)
› Each vertex has a unique self-assigned
identifier (RID)
› Format: #:<cluster-id>:<cluster-position>
› List of properties
› Edge’s RID (in & out)
/ Copyright ©2014 by Readify Limited21
- 22. Page
Edges
› Record identifier (RID)
› Each record has it’s own self-assigned unique
ID
› Composed of 2 parts
#:<cluster-id>:<cluster-position>
› in (RID of the incoming vertex)
› out (RID of the outgoing vertex)
/ Copyright ©2014 by Readify Limited22
- 23. Page
Relationships
/ Copyright ©2014 by Readify Limited23
› Doesn't make use of JOINS like RDBMS
› Physical links O(1)
› Relationship managed by storing the edge’s RID
in both vertices as “out” and “in”
› For 1-to-n relationship collections of rid are
used
- 24. Page
Relationships
/ Copyright ©2014 by Readify Limited24
drives
out: [#14:10]
name: Abdo
@class: Driver
#14:10
#13:20
out: [#13:20]
in: [#15:20]
license: A134
@class: Drives
#15:20
in: [#14:10]
model: Q7
doors: 5
name: BMW
@class: Car
- 26. Page
API Interfaces
/ Copyright ©2014 by Readify Limited26
• Support for TinkerPop standard
for Graph DB: Gremlin language
and Blueprints API
• SQL + extensions for graphs
• JDBC driver to connect any BI tool
• HTTP/JSON support
• Drivers in Java, Node.js, Python,
PHP, .NET, Perl, C/C++ and more
- 27. Page
Getting Started for Free
/ Copyright ©2014 by Readify Limited27
OrientDB Community Edition is FREE for
any purpose (Apache 2 license)
http://orientdb.com/docs
Udemy Getting Started Training is Free
★★★★★
http://www.orientechnologies.com/getting-started