SlideShare a Scribd company logo
1 of 17
1
Today‟s Talk
• 10gen
• MongoDB
• Real World Applications / Use Cases
• Community




                                  2
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
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
Database Landscape

                            Memcached
Scalability & Performance




                               Key / Value




                                                               RDBMS




                                      Depth of functionality
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"
          }
  ]
}
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} );
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()
Query Operators
• Conditional Operators
  • $all, $exists, $mod, $ne, $in, $nin, $nor, $or, $size, $type
  • $lt, $lte, $gt, $gte
  > db.posts.find({tags : {$in : [“Manga”, “animation}]})
• Regular expressions
  > db.posts.find({author: /^r/})
Indexes
 // Index nested documents
 > db.posts.ensureIndex( “comments.author”:1 )
   db.posts.find({„comments.author‟:‟Fred‟})


 // Index on tags
 > db.posts.ensureIndex( tags: 1)
 > db.posts.find( { tags: ‟Manga‟ } )
Replica Sets


       Write
                Primary
       Read
                           Asynchronous
               Secondary   Replication
       Read


               Secondary
       Read
Replica Sets


       Write
                Primary
       Read

               Secondary
       Read


               Secondary
       Read
Replica Sets


                Primary
                           Automatic
                           Leader Election
       Write
                Primary
       Read

               Secondary
       Read
Replica Sets


               Secondary
      Read

       Write
                Primary
       Read

               Secondary
       Read
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
MongoDB Use Cases



                 Content
  Analytics                  E-Commerce
               Management




 Advertising     Gaming     Social Network
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

More Related Content

Recently uploaded

Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdfPedro Manuel
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6DianaGray10
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAshyamraj55
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfAijun Zhang
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfinfogdgmi
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UbiTrack UK
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1DianaGray10
 
Artificial Intelligence & SEO Trends for 2024
Artificial Intelligence & SEO Trends for 2024Artificial Intelligence & SEO Trends for 2024
Artificial Intelligence & SEO Trends for 2024D Cloud Solutions
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationIES VE
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1DianaGray10
 
Empowering Africa's Next Generation: The AI Leadership Blueprint
Empowering Africa's Next Generation: The AI Leadership BlueprintEmpowering Africa's Next Generation: The AI Leadership Blueprint
Empowering Africa's Next Generation: The AI Leadership BlueprintMahmoud Rabie
 
Things you didn't know you can use in your Salesforce
Things you didn't know you can use in your SalesforceThings you didn't know you can use in your Salesforce
Things you didn't know you can use in your SalesforceMartin Humpolec
 
Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.francesco barbera
 
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...DianaGray10
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024SkyPlanner
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Will Schroeder
 
Comparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioComparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioChristian Posta
 
Cloud Revolution: Exploring the New Wave of Serverless Spatial Data
Cloud Revolution: Exploring the New Wave of Serverless Spatial DataCloud Revolution: Exploring the New Wave of Serverless Spatial Data
Cloud Revolution: Exploring the New Wave of Serverless Spatial DataSafe Software
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaborationbruanjhuli
 

Recently uploaded (20)

Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdf
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdf
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdf
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1
 
Artificial Intelligence & SEO Trends for 2024
Artificial Intelligence & SEO Trends for 2024Artificial Intelligence & SEO Trends for 2024
Artificial Intelligence & SEO Trends for 2024
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
 
Empowering Africa's Next Generation: The AI Leadership Blueprint
Empowering Africa's Next Generation: The AI Leadership BlueprintEmpowering Africa's Next Generation: The AI Leadership Blueprint
Empowering Africa's Next Generation: The AI Leadership Blueprint
 
Things you didn't know you can use in your Salesforce
Things you didn't know you can use in your SalesforceThings you didn't know you can use in your Salesforce
Things you didn't know you can use in your Salesforce
 
Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.Digital magic. A small project for controlling smart light bulbs.
Digital magic. A small project for controlling smart light bulbs.
 
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
 
Comparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and IstioComparing Sidecar-less Service Mesh from Cilium and Istio
Comparing Sidecar-less Service Mesh from Cilium and Istio
 
Cloud Revolution: Exploring the New Wave of Serverless Spatial Data
Cloud Revolution: Exploring the New Wave of Serverless Spatial DataCloud Revolution: Exploring the New Wave of Serverless Spatial Data
Cloud Revolution: Exploring the New Wave of Serverless Spatial Data
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
 

Technical Introduction to MongoDB

  • 1. 1
  • 2. Today‟s Talk • 10gen • MongoDB • Real World Applications / Use Cases • Community 2
  • 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()
  • 9. Query Operators • Conditional Operators • $all, $exists, $mod, $ne, $in, $nin, $nor, $or, $size, $type • $lt, $lte, $gt, $gte > db.posts.find({tags : {$in : [“Manga”, “animation}]}) • Regular expressions > db.posts.find({author: /^r/})
  • 10. Indexes // Index nested documents > db.posts.ensureIndex( “comments.author”:1 )  db.posts.find({„comments.author‟:‟Fred‟}) // Index on tags > db.posts.ensureIndex( tags: 1) > db.posts.find( { tags: ‟Manga‟ } )
  • 11. Replica Sets Write Primary Read Asynchronous Secondary Replication Read Secondary Read
  • 12. Replica Sets Write Primary Read Secondary Read Secondary Read
  • 13. Replica Sets Primary Automatic Leader Election Write Primary Read Secondary Read
  • 14. Replica Sets Secondary Read Write Primary Read Secondary Read
  • 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