3. 10gen
• 10gen began the MongoDB project
• Development, support, and services
• ~125 employees
• New York, Palo Alto, London, Dublin
• $31M+ funding (last round, Sept 2011)
• Investors: Sequoia, Flybridge, Union Square
3
4. MongoDB
MongoDB is a scalable, high-performance
open source NoSQL database
• Document-Oriented Storage
• Replication and High Availability
• Auto-Sharding
• Fast In-Place updates
• Ad-hoc Querying
• Full index support
• Map/Reduce
5. Database Landscape
Memcached
Scalability & Performance
Key / Value
RDBMS
Depth of functionality
6. What‟s a document anyway?
doc =
{
author : "roger",
date : "Sat Jul 24 2010 19:47:11 GMT-0700 (PDT)",
text : "Spirited Away",
tags : [ "Tezuka", "Manga" ],
comments : [
{
author : "Fred",
date : "Sat Jul 24 2010 20:51:03 GMT-0700 (PDT)",
text : "Best Movie Ever"
}
]
}
7. Atomic Updates
• $set, $unset, $inc, $push, $pull, …
> comment = { author: “john”,
date: new Date(),
text: “I didn„t like it so much”}
> db.posts.update( { _id: doc._id },
$push: {comments: comment} );
8. Querying
// find posts tagged with Manga
> db.posts.find( {tags: “Manga”} )
// find posts commented on by Fred
> db.posts.find( {“comments.author” : “Fred” } )
// Aggregation
> db.posts.find( {author: „roger‟} ).count()
15. Write Read
MongoS MongoS MongoS MongoS
Key Range Key Range Key Range Key Range
-∞..n1, n6..n7 n1..n2, n7..n8 n3..n4, n8..n9 n5..n6, n9..∞
Primary Primary Primary Primary
Secondary Secondary Secondary Secondary
Secondary Secondary Secondary Secondary
16. MongoDB Use Cases
Content
Analytics E-Commerce
Management
Advertising Gaming Social Network
17. Community
• MongoDB Days
• 23+ MongoDB Days reaching
over 10,000 people annually
• MongoNYC May 23rd
• MongoBoston in Fall
• MongoDB User Groups
• 28 cities with MUGs
• Join Boston MUG
• http://bit.ly/BostonMUG
• User Forum
• http://bit.ly/mongodb-user
• 15,000+ questions answered
• Office Hours
• Coming soon… Suggestions?
17