• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Intro to RavenDB

Intro to RavenDB






Total Views
Views on SlideShare
Embed Views



3 Embeds 18

http://lanyrd.com 12
http://coderwall.com 5
http://www.instapaper.com 1



Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
Post Comment
Edit your comment
  • 1970 Edgar F Codd – A Relational Model of Data for Large Shared Data Bank

Intro to RavenDB Intro to RavenDB Presentation Transcript

  • RavenDB What is it?
  • Hi, My Name Is… Alonso Robles  @alonsorobles  http://alonsorobles.com Principal Consultant at Headspring  @headspring  http://headspring.com
  • Before we begin… Central Texas GiveCamp  Developers  Sponsors  http://ctxgivecamp.org RavenDB Boot Camp  September 5th-6th  2-day hands-on workshop  Headspring, Austin, TX  http://headspring.com
  • Agenda NoSQL Crash Course Overview of RavenDB Development with RavenDB
  • Crash Course NoSQuirreLs? But why?
  • History of the Datum We (the programmers) gave birth to data We put it (the data) in memory We discovered a way to persist it So we put it in files And we had more problems to solve…
  • From Data To Management  Common problems  Data retrieval  Concurrent writes  Optimize for space  Data aggregation  Lead to the introduction of  RDBMS  SQL
  • RDBMS + SQL Strengths Limitations ACID  Scaling horizontally is hard  Atomic  Consistent  Scaling vertically is expensive  Isolated  Object to relation mapping can  Durable be difficult Relational  Table / Row Rich query support Data Integrity  Foreign Keys  Enforced Schema
  • CAP Theorem
  • Polyglot Persistence Relational  MS SQL Server  MySQL Key-Value  Redis  Dynamo Column-Oriented  BigTable  Cassandra Document-Oriented  MongoDB  RavenDB
  • Key-Value  Simplest of all data stores  IDictionary<string, object>  Key is a string  Value is a blob  Schema free  Query by key  Or key range sometimes  Good candidate for  User session storage  Shopping carts
  • Document-Oriented Like a key-value store Document in known format  JSON  BSON  XML Supports server side operations Good for  Complex objects  DDD Aggregates
  • Column-Oriented  Not relational at all  Schema free  Concepts to understand  Column families  Row Keys  Columns  A Key Value Pair  Good for  Large amounts of sparse data
  • Is SQL Dead? Nope It’s still the strongest option for  Reports  Dynamic Aggregations  Data integrity enforcement Remember  NoSQL = Not Only SQL  Or… NoSQuirreLs
  • RavenDBThe Very Brief Overview
  • What is it? It’s a document database Built on .NET for .NET JSON data storage Built on top of Lucene Open source Gets out of your way It just works Just code – studio not required
  • Features I Really Like Scalable via shards and/or replication Schema free Easy to learn and develop against Full power of Lucene  Full-text search  Faceted search  Auto suggest  More like this Multiple deployment options
  • Development Oh yeah! It’s fun!
  • .NET Client API IDocumentStore  Session factory  Thread safe heavy weight object  Thread safe  Use single instance per application IDocumentSession  Interacts with the database  Not thread safe light weight object  Implements Unit of Work pattern  Use one per thread or web request
  • CRUD Operations Create  IDocumentSession.Store(object) Retrieve  IDocumentSession.Load<T>(string) Update  Retrieve and modify Delete  IDocumentSession.Delete(object) Don’t Forget  IDocumentSession.SaveChanges()
  • Query Operations Rich LINQ support Basic Query  IDocumentSession.Query<T>()  Returns a IRavenQueryable<T>  Implements IQueryable<T> Filtering  Use a Where(…) clause Paging  Use Skip(int) and Take(int)
  • Dynamic Indexes Automagically created on demand Raven learns about your application Dynamic indexes marked as temporary  Removed if not used  Promoted to permanent if used a lot
  • Static Indexes Do it your self It’s just a class  That defines  Implicit or explicit index name  One or more map functions  Optional reduce function  Optional transform function  May define many other options like  Field options  Storage  Analysis
  • More to Learn Querying  Using the query statistics Indexes  More options  Hierarchical indexes  Polymorphic indexes Projections Document relationships Attachments Shards and Replication
  • Even More to Learn Advanced topics  Transaction support  Document metadata  Spatial search  Dynamic fields  Database commands Server administration Deployment options Multi-tenancy Using bundles
  • Where to Learn More Official website  http://ravendb.net Google group  http://groups.google.com/group/ravendb GitHub  http://github.com/ravendb/ravendb Headspring  Exclusive North American Training Partner  RavenDB Boot Camp on Sept 5th-6th  More info @ http://headspring.com Follow me on Twitter  @alonsorobles
  • The End Alonso Robles @alonsorobleshttp://alonsorobles.com