nosql - motivation and overview
DESCRIPTION
Introduction to NoSQL, Redis and CouchDB presented by Jonathan Weiss at BarCampRuhr4TRANSCRIPT
![Page 1: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/1.jpg)
Jonathan WeissPeritor GmbH
N✮SQLData-Storage jenseits von SQL
![Page 2: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/2.jpg)
Wer?
Ruby-Entwickler
Open-Source-Contributor (http://github.com/jweiss)
@jweiss
2
![Page 3: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/3.jpg)
N✮SQL-Datenbanken?
3
Built for the Web
Skalierbar
Performant
Flexibles Datenschema
![Page 4: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/4.jpg)
4
DynamoCouchDBDynomite
Tokyo Tyrant
MongoDB
Riak
Amazon SimpleDB
Redis Memcached
BigTableAmazon S3
Cassandra
Lotus Notes
Excel ;)Neo4j
Project Voldemort HBase
![Page 5: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/5.jpg)
Der Status-Quo
Relationale Datenstrukturen
SQL
Transaktionssicherheit
Locking
5
![Page 6: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/6.jpg)
Das Problem
6
![Page 7: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/7.jpg)
Das Problem
7
![Page 8: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/8.jpg)
Die Lösung
8
”Simplicity is prerequisite for reliability“— Edsger W. Dijkstra
![Page 9: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/9.jpg)
Die Lösung
key => “value”
9
![Page 10: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/10.jpg)
Dokumente
10
![Page 11: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/11.jpg)
Integrität
11
![Page 12: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/12.jpg)
Eventual Consistency
12
![Page 13: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/13.jpg)
Append-Only
13
![Page 14: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/14.jpg)
Append-Only
14
Update
![Page 15: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/15.jpg)
Append-Only
15
Update
![Page 16: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/16.jpg)
Skalierbarkeit
16
![Page 17: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/17.jpg)
Tools
17
![Page 18: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/18.jpg)
Tools
18
DynamoCouchDBDynomite
Tokyo Tyrant
MongoDB
Riak
Amazon SimpleDB
Redis Memcached
BigTableAmazon S3
Cassandra
Lotus Notes
Excel ;)Neo4j
Project Voldemort HBase
![Page 19: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/19.jpg)
Tools
19
DynamoCouchDBDynomite
Tokyo Tyrant
MongoDB
Riak
Amazon SimpleDB
Redis Memcached
BigTableAmazon S3
Cassandra
Lotus Notes
Excel ;)Neo4j
Project Voldemort HBase
![Page 20: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/20.jpg)
Redis
Simpler Key-Value-Store
Speichert Strings, Listen und Sets
Persistenz über Snapshots oder Append-Logs
20
![Page 21: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/21.jpg)
Redis
21
![Page 22: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/22.jpg)
Redis
set foo 4
1000
+OK
22
Request
Response
![Page 23: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/23.jpg)
Scaling
Master-Slave mittels Snapshots
Multiple Master mittels Hash Ring
23
![Page 24: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/24.jpg)
Einsatz-Szenarien
Persistenter Cache
Session-Store
Realtime-Data: Monitoring, Trading, ...
Simple Message Queue
Shared State
24
![Page 25: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/25.jpg)
25
CouchDBrelax
![Page 26: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/26.jpg)
CouchDB
Dokument-orientiert
26
![Page 27: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/27.jpg)
27
”CouchDB is built of the Web“— Jacob Kaplan-Moss
![Page 28: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/28.jpg)
CouchDB Document
28
{ "_id": "BCCD12CBB", "_rev": "1-‐AB764C", "type": "person", "name": "Darth Vader", "age": 63, "headware": ["Helmet", "Sombrero"], "dark_side": true}
![Page 29: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/29.jpg)
CouchDB Document
29
{ "_id": "BCCD12CBB", "_rev": "1-‐AB764C", "type": "person", "name": "Darth Vader", "age": 63, "headware": ["Helmet", "Sombrero"], "dark_side": true}
![Page 30: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/30.jpg)
CouchDB Document
30
{ "_id": "BCCD12CBB", "_rev": "1-‐AB764C", "type": "person", "name": "Darth Vader", "age": 63, "headware": ["Helmet", "Sombrero"], "dark_side": true}
![Page 31: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/31.jpg)
CouchDB - CRUD
Erstellen/Aktualisieren:
PUT /starwars/BCCD12CBB
Lesen:
GET /starwars/BCCD12CBB
Löschen:
DELETE /starwars/BCCD12CBB
31
![Page 32: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/32.jpg)
CouchDB
Wie komme ich an meine Daten?
32
![Page 33: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/33.jpg)
CouchDB
33
Views!
![Page 34: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/34.jpg)
CouchDB
34
function(doc) { if (doc.headware) { for (var hat in doc.headware) { emit(hat, 1); } }}
![Page 35: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/35.jpg)
CouchDB
35
function(keys, values, rereduce) { return sum(values);}
![Page 36: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/36.jpg)
Libraries
SimplyStored: Ruby wrapper
http://github.com/peritor/simply_stored
36
ModelsAssociationsCallbacksValidationsDynamic finderS3 attachmentsParanoid delete
![Page 37: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/37.jpg)
Libraries
37
![Page 38: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/38.jpg)
B-Tree
38
![Page 39: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/39.jpg)
Crash-Proof
39
![Page 40: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/40.jpg)
Offline by default
40
![Page 41: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/41.jpg)
Replication
41
![Page 42: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/42.jpg)
CouchDB
POST /_replication
42
![Page 43: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/43.jpg)
Und?
Daten sind wieder König
43
![Page 44: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/44.jpg)
Aber!
Kein goldener Hammer
44
![Page 45: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/45.jpg)
45
![Page 46: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/46.jpg)
46
![Page 47: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/47.jpg)
Peritor
47
Cloud-Management und -Deployment made easy
http://scalarium.com
![Page 48: NoSQL - Motivation and Overview](https://reader035.vdocuments.us/reader035/viewer/2022062617/54b75fb14a7959a23c8b4620/html5/thumbnails/48.jpg)
© Peritor GmbH - Alle Rechte Vorbehalten
Peritor GmbHBlücherstr. 22, Hof III Aufgang 610961 Berlin
Tel.: +49 (0)30 69 20 09 84 0Fax: +49 (0)30 69 20 09 84 9
Internet: www.peritor.comE-Mail: [email protected]