2011-12-13 NoSQL aus der Praxis

  • Published on
    27-Jan-2015

  • View
    105

  • Download
    2

Embed Size (px)

DESCRIPTION

Vortrag fr die .NET User Group Frankfurt

Transcript

  • 1. aus der Praxis13.12.2011Dipl.-Inf. (FH) Johannes HoppeM.Sc. Johannes Hofmeister

2. Johannes Hoppe.NET Webentwickler www.johanneshoppe.de 3. Johannes Hofmeister.NET Domnenexpertewww.twitter.com/pro_cessor 4. 01Not only SQL 5. Daten 2002 2004 2006 2008 2010 2012 6. Daten Facebook hat 60k Server (2010) Google hat 450k Server (2006) Microsoft: hat 100k - 500k Server (seit Azure) Facebook Server Footprint 7. Trend 1: increasing data sizesTrend 2: more connectedness (web 2.0)Trend 3: more individualization (fever structure) 8. verteilte und horizontale Skalierbarkeitkein relationales Datenmodell (kein SQL)schemafrei / schwache Schemarestriktionenanderes Konsistenzmodell 9. Scale-upVertikale SkalierungServer auf mehr Leistungsfhigkeit trimmen 10. Scale-outhorizontale SkalierungEinfgen von Nodes (Rechnerknoten) 11. Schemafreikein ALTER TABLEkein Wartungsfenster *Datenversionierung im Code!* morgens ausschlafen 12. Anforderungenan ein verteiltes System ConsistencyKonsistenz Partition Availability Tolerance VerfgbarkeitAusfalltoleranz 13. CAP Theorem 2000: E. Brewer, N. Lynch You can satisfyat most 2 out of the 3 requirements 14. Consistency The system is in a consistent state after an operation All clients see the same data Strong consistency (ACID)vs. eventual consistency (BASE)ACID: Atomicity, Consistency, Isolation and DurabilityBASE: Basically Available, Soft state, Eventually consistent 15. Availability System is always on, no downtime Node failure tolerance all clients can find some available replica Software/hardware upgrade tolerance 16. Partition tolerance System continues to function even whensplit into disconnected subsets (network disruption) Not only for reads, but writes as well 17. Drum prfe,wer sich ewig bindet.Friedrich Schiller 18. Kategorisierung Key-Value stores Document stores Wide Column stores Graphdatenbanken weitere 19. 02MongoDB 20. NoSQL MongoDB Quick Reference Cards http://www.10gen.com/reference 21. Deployment Standardverzeichnis erstellen: c:datadb Server-Start: mongod.exe Shell: mongo.exe 22. BSON Master/SlaveJavaScript C# DriverSharding GNU AGPL 23. JSON BSONAll JSON documents are stored in a binaryformat called BSON. BSON supports aricher set of types than JSON.http://bsonspec.org 24. CRUD Create(in the shell) db.people.save({name: Smith, age: 30});See how the save command works: db.foo.save 25. CRUD Createwith a bit JavaScriptfor(i=0; icurl -X GET http://localhost:8080/docs/Categories/1 -iHTTP/1.1 200 OKContent-Type: application/json; charset=utf-8ETag: 00000000-0000-0200-0000-000000000004{ "Name" : "Normal Importance", "Color" : "green"} 45. Lucene Style QueriesClassic Linq Style Lucene Stylevar notes = sessionvar notes = session.Advanced.Query() .LuceneQuery().Where(n => n.Category == Important") .Where(Category:Important").ToArray();.ToArray(); 46. 04Tabellen Dokumente 47. 05Key and Index Strategies 48. FRAGEN? 49. https://webnote.codeplex.com/ 50. Vielen Dank!Johannes HoppeJohannes Hofmeister 51. BildnachweiseAusgewhlter Ordner Spectral-Design Fotolia.comWarnhinweis-Schild Sascha Tiebel Fotolia.comListe abhaken Dirk Schumann Fotolia.comStressed businessman Selecstock Fotolia.com

Recommended

View more >