SlideShare ist ein Scribd-Unternehmen logo
1 von 30
Downloaden Sie, um offline zu lesen
Scott Hernandez




 ©"Copyright"2010"10gen"Inc."
Release History
•  First release – February 2009
•  v1.0 - August 2009
•  v1.2 - December 2009 – MapReduce, ++
•  v1.4 - March 2010 – Concurrency, Geo
•  V1.6 - August 2010 – Sharding, Replica Sets
•  V1.8 – March 2011 – Journaling, Geosphere
•  V2.0 -- Sep 2011 – V1 Indexes, Concurrency
Types of Non-Relational Data Models
•  Key-value stores
•  Document stores
•  Column-oriented databases
•  Graph databases
What is MongoDB
•  Document Store
•  Horizontally Scalable
•  High Performance
MongoDB vs Traditional RDBMS
             server"
                              schema"
databases" coll
                  ections
                          "
        contain"tables""
                            documen
                                     ts"
                       contain"rows"
  joins"
Terminology

RDBMS&           Mongo&
Table,"View"     Collection"
Row(s)"          JSON"Document"
Index"           Index"
Join"            Embedded"Document"
Partition"       Shard"
Partition"Key"   Shard"Key"
MongoDB is a Single-Master System
•  All writes are to a primary (master)
•  Failure of the primary is detected, and a new
   one is elected
•  Application writes get an error if there is no
   quorum to elect a new master
  •  Reads can continue
Consistency Models
•  Relational databases support transactions
  •  Can only see committed changes
  •  Commits/aborts span multiple changes
  •  Read-only transaction flavors
    •  Read committed, repeatable read, etc
•  Single vs Multi-Master
Single Master
•  All writes go to a single master and then
   replicated
•  Replication can provide read scalability
•  Writing becomes a bottleneck
  •  Physical limitations (seek time)
  •  Throughput of a single I/O subsystem
Single Master - Sharding
•  Partition the primary key space via hashing
•  Set up a duplicate system for each shard
  •  The write-rate limitation now applies to each
     shard
  •  Joins or aggregation across shards are
     problematic
  •  Can the data be re-sharded on a live system?
  •  Can shards be re-balanced on a live system?
MongoDB Storage Management
•  Memory-mapped Database files
•  Files are (pre)allocated as needed
•  Indexes (B*-trees) point to documents
Documents
Blog Post Document"
"
 p = { author: “sridhar”,"
       date: new Date(),"
       title: “Using the C# driver with MongoDB”,"
       tags: [“NoSQL”, “Mongo”, “MongoDB”]}"
"
> db.posts.save(p)"
Querying
 >db.posts.find()"
"
    { _id : ObjectId("4c4ba5c0672c685e5e8aabf3"),"
      author : “sridhar", "
      date : “Mon Jul 11 2011 19:47:11 GMT-0700
(PDT)", "
        title: “Using the C# driver with MongoDB”,"
        tags: [“NoSQL”, “Mongo”, “MongoDB”]} "
  "
Secondary Indexes
Create index on any Field in Document"
"
   // 1 means ascending, -1 means descending"
"
   >db.posts.ensureIndex({author: 1})"
"
   >db.posts.find({author: ʻsridhar'}) "
 "
   { _id     : ObjectId("4c4ba5c0672c685e5e8aabf3"),"
     author : “sridhar", "
     ... }"
Query Operators
•  Conditional Operators "
  •  $all, $exists, $mod, $ne, $in, $nin, $nor, $or, $size, $type"
  •  $lt, $lte, $gt, $gte"
  "
  // find posts with any tags "
  > db.posts.find( {tags: {$exists: true }} )"
  "
  // find posts matching a regular expression"
  > db.posts.find( {author: /^sri*/i } )"
  "
  // count posts by author"
  > db.posts.find( {author: ʻsridharʼ} ).count()"
Atomic Operations
•  $set, $unset, $inc, $push, $pushAll, $pull,
  $pullAll, $bit"

> comment = { author: “fred”, "
              date: new Date(),"
              text: “Interesting blog post”}"
"
 > db.posts.update( { _id: “...” }, "
     "    "$push: {comments: comment} );"
"
Nested Documents

{ _id : ObjectId("4c4ba5c0672c685e5e8aabf3"), "
  author : “sridhar","
  date : “Mon Jul 11 2011 19:47:11 GMT-0700 (PDT)", "
  text : “Using the C# driver with MongoDB","
  tags : [ “NoSQL", “Mongo", “MongoDB" ],"
  comments : ["
       "{"
       "       "author : "Fred","
       "       "date : “Mon Jul 11 2011 20:51:03 GMT-0700 (PDT)","
       "       "text : “Interesting blog post""
       "}"
  ]}"
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: ’Mongo’ } )

 // geospatial index
 > db.posts.ensureIndex( “author.location”: “2d” )
 > db.posts.find( “author.location” : { $near : [22,42] } )
MongoDB – More
•  Geo-spatial queries
  •  Require a geo index
  •  Find points near a given point
  •  Find points within a polygon/sphere
•  Built-in Map-Reduce
  •  The caller provides map and reduce functions
    written in JavaScript
Scaling MongoDB
•  Replication - Read scalability
  •  Master/Slave
  •  Replica Sets
•  Sharding – Read and write scalability
  •  Collections are sharded
  •  Each shard is served by its own replica set
  •  Shard key ranges are automatically balanced
Write"       Read"


      MongoS"     MongoS"     MongoS"       MongoS"




 Key Range"      Key Range"    Key Range"       Key Range"
 0..30"          31..60"       61..90"          91.. 100"


 Primary"        Primary"      Primary"         Primary"


Secondary"      Secondary"    Secondary"       Secondary"


Secondary"      Secondary"    Secondary"       Secondary"
MongoDB Access
•  Drivers are available in many languages
  •  10gen supported
     •  C, C# (.Net), C++, Erlang, Haskell, Java,
        JavaScript, Perl, PHP, Python, Ruby, Scala
  •  Community supported
    •  Clojure, ColdFusion, F#, Go, Groovy, Lua, R
    •  http://www.mongodb.org/display/DOCS/Overview+-
       +Writing+Drivers+and+Tools
MongoDB Availability
•  Source
  •  https://github.com/mongodb/mongo
•  Server
  •  License: AGPL
  •  http://www.mongodb.org/downloads
•  Drivers
  •  License: Apache
  •  http://www.mongodb.org/display/DOCS/Drivers
download at mongodb.org

                  We’re"Hiring"!"
       Engineers,"Sales,"Evangelist,"Marketing,"Support,"Developers""

        conferences,"appearances,"and"meetups"
                   http://www.10gen.com/events"
                                "


   Facebook""""""""""|"""""""""Twitter"""""""""|"""""""""LinkedIn"
http://bit.ly/mongoQ""           @mongodb"                  http://linkd.in/joinmongo"



                             ©"Copyright"2010"10gen"Inc."
Use cases and customers
•  Use cases
•  Case studies
Content Management
Gaming
Analytics
try at try.mongodb.org




      ©"Copyright"2010"10gen"Inc."
download at mongodb.org

                     We’re"Hiring"!"
                 sridhar@10gen.com"
                      @snanjund"
        conferences,"appearances,"and"meetups"
                   http://www.10gen.com/events"
                                "


   Facebook""""""""""|"""""""""Twitter"""""""""|"""""""""LinkedIn"
http://bit.ly/mongoQ""        @mongodb"                  http://linkd.in/joinmongo"



                          ©"Copyright"2010"10gen"Inc."

Weitere ähnliche Inhalte

Was ist angesagt?

How To Connect Spark To Your Own Datasource
How To Connect Spark To Your Own DatasourceHow To Connect Spark To Your Own Datasource
How To Connect Spark To Your Own DatasourceMongoDB
 
MongoDB at the Silicon Valley iPhone and iPad Developers' Meetup
MongoDB at the Silicon Valley iPhone and iPad Developers' MeetupMongoDB at the Silicon Valley iPhone and iPad Developers' Meetup
MongoDB at the Silicon Valley iPhone and iPad Developers' MeetupMongoDB
 
MongoDB Pros and Cons
MongoDB Pros and ConsMongoDB Pros and Cons
MongoDB Pros and Consjohnrjenson
 
Building Your First Application with MongoDB
Building Your First Application with MongoDBBuilding Your First Application with MongoDB
Building Your First Application with MongoDBMongoDB
 
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...MongoDB
 
Strengths and Weaknesses of MongoDB
Strengths and Weaknesses of MongoDBStrengths and Weaknesses of MongoDB
Strengths and Weaknesses of MongoDBlehresman
 
Practical Elasticsearch - real world use cases
Practical Elasticsearch - real world use casesPractical Elasticsearch - real world use cases
Practical Elasticsearch - real world use casesItamar
 
Back to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsBack to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsJoe Drumgoole
 
MongoDB Best Practices in AWS
MongoDB Best Practices in AWS MongoDB Best Practices in AWS
MongoDB Best Practices in AWS Chris Harris
 
Back to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLBack to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLJoe Drumgoole
 
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101MongoDB
 
Scaling with MongoDB
Scaling with MongoDBScaling with MongoDB
Scaling with MongoDBMongoDB
 
Back to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationBack to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationMongoDB
 
Scaling with MongoDB
Scaling with MongoDBScaling with MongoDB
Scaling with MongoDBRick Copeland
 
Challenges with MongoDB
Challenges with MongoDBChallenges with MongoDB
Challenges with MongoDBStone Gao
 

Was ist angesagt? (20)

How To Connect Spark To Your Own Datasource
How To Connect Spark To Your Own DatasourceHow To Connect Spark To Your Own Datasource
How To Connect Spark To Your Own Datasource
 
The What and Why of NoSql
The What and Why of NoSqlThe What and Why of NoSql
The What and Why of NoSql
 
MongoDB at the Silicon Valley iPhone and iPad Developers' Meetup
MongoDB at the Silicon Valley iPhone and iPad Developers' MeetupMongoDB at the Silicon Valley iPhone and iPad Developers' Meetup
MongoDB at the Silicon Valley iPhone and iPad Developers' Meetup
 
MongoDB
MongoDBMongoDB
MongoDB
 
MongoDB Pros and Cons
MongoDB Pros and ConsMongoDB Pros and Cons
MongoDB Pros and Cons
 
Building Your First Application with MongoDB
Building Your First Application with MongoDBBuilding Your First Application with MongoDB
Building Your First Application with MongoDB
 
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...
Webinar: Developing with the modern App Stack: MEAN and MERN (with Angular2 a...
 
Strengths and Weaknesses of MongoDB
Strengths and Weaknesses of MongoDBStrengths and Weaknesses of MongoDB
Strengths and Weaknesses of MongoDB
 
Mongo db japan
Mongo db japanMongo db japan
Mongo db japan
 
Mongodb
MongodbMongodb
Mongodb
 
Practical Elasticsearch - real world use cases
Practical Elasticsearch - real world use casesPractical Elasticsearch - real world use cases
Practical Elasticsearch - real world use cases
 
Back to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in DocumentsBack to Basics Webinar 3 - Thinking in Documents
Back to Basics Webinar 3 - Thinking in Documents
 
MongoDB Best Practices in AWS
MongoDB Best Practices in AWS MongoDB Best Practices in AWS
MongoDB Best Practices in AWS
 
Back to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQLBack to Basics Webinar 1 - Introduction to NoSQL
Back to Basics Webinar 1 - Introduction to NoSQL
 
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101
MongoDB Days Silicon Valley: Jumpstart: Ops/Admin 101
 
Scaling with MongoDB
Scaling with MongoDBScaling with MongoDB
Scaling with MongoDB
 
Back to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB ApplicationBack to Basics Webinar 2: Your First MongoDB Application
Back to Basics Webinar 2: Your First MongoDB Application
 
MongoDB for Developers
MongoDB for DevelopersMongoDB for Developers
MongoDB for Developers
 
Scaling with MongoDB
Scaling with MongoDBScaling with MongoDB
Scaling with MongoDB
 
Challenges with MongoDB
Challenges with MongoDBChallenges with MongoDB
Challenges with MongoDB
 

Andere mochten auch

Schema Design at Scale
Schema Design at ScaleSchema Design at Scale
Schema Design at ScaleRick Copeland
 
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)MongoDB
 
Scalable Event Analytics with MongoDB & Ruby on Rails
Scalable Event Analytics with MongoDB & Ruby on RailsScalable Event Analytics with MongoDB & Ruby on Rails
Scalable Event Analytics with MongoDB & Ruby on RailsJared Rosoff
 
Schema Design with MongoDB
Schema Design with MongoDBSchema Design with MongoDB
Schema Design with MongoDBrogerbodamer
 
MongoDB for Time Series Data: Setting the Stage for Sensor Management
MongoDB for Time Series Data: Setting the Stage for Sensor ManagementMongoDB for Time Series Data: Setting the Stage for Sensor Management
MongoDB for Time Series Data: Setting the Stage for Sensor ManagementMongoDB
 
MongoDB for Time Series Data: Schema Design
MongoDB for Time Series Data: Schema DesignMongoDB for Time Series Data: Schema Design
MongoDB for Time Series Data: Schema DesignMongoDB
 
MongoDB Schema Design
MongoDB Schema DesignMongoDB Schema Design
MongoDB Schema DesignMongoDB
 
MongoDB Schema Design: Four Real-World Examples
MongoDB Schema Design: Four Real-World ExamplesMongoDB Schema Design: Four Real-World Examples
MongoDB Schema Design: Four Real-World ExamplesMike Friedman
 

Andere mochten auch (8)

Schema Design at Scale
Schema Design at ScaleSchema Design at Scale
Schema Design at Scale
 
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
MongoDB Schema Design (Richard Kreuter's Mongo Berlin preso)
 
Scalable Event Analytics with MongoDB & Ruby on Rails
Scalable Event Analytics with MongoDB & Ruby on RailsScalable Event Analytics with MongoDB & Ruby on Rails
Scalable Event Analytics with MongoDB & Ruby on Rails
 
Schema Design with MongoDB
Schema Design with MongoDBSchema Design with MongoDB
Schema Design with MongoDB
 
MongoDB for Time Series Data: Setting the Stage for Sensor Management
MongoDB for Time Series Data: Setting the Stage for Sensor ManagementMongoDB for Time Series Data: Setting the Stage for Sensor Management
MongoDB for Time Series Data: Setting the Stage for Sensor Management
 
MongoDB for Time Series Data: Schema Design
MongoDB for Time Series Data: Schema DesignMongoDB for Time Series Data: Schema Design
MongoDB for Time Series Data: Schema Design
 
MongoDB Schema Design
MongoDB Schema DesignMongoDB Schema Design
MongoDB Schema Design
 
MongoDB Schema Design: Four Real-World Examples
MongoDB Schema Design: Four Real-World ExamplesMongoDB Schema Design: Four Real-World Examples
MongoDB Schema Design: Four Real-World Examples
 

Ähnlich wie 10gen MongoDB Video Presentation at WebGeek DevCup

Dev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBDev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBMongoDB
 
Mongodb intro
Mongodb introMongodb intro
Mongodb introchristkv
 
MongoDB: a gentle, friendly overview
MongoDB: a gentle, friendly overviewMongoDB: a gentle, friendly overview
MongoDB: a gentle, friendly overviewAntonio Pintus
 
MongoDB and Ruby on Rails
MongoDB and Ruby on RailsMongoDB and Ruby on Rails
MongoDB and Ruby on Railsrfischer20
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDBSean Laurent
 
MongoDB Hadoop DC
MongoDB Hadoop DCMongoDB Hadoop DC
MongoDB Hadoop DCMike Dirolf
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDBRavi Teja
 
OSDC 2012 | Building a first application on MongoDB by Ross Lawley
OSDC 2012 | Building a first application on MongoDB by Ross LawleyOSDC 2012 | Building a first application on MongoDB by Ross Lawley
OSDC 2012 | Building a first application on MongoDB by Ross LawleyNETWAYS
 
Mongo db eveningschemadesign
Mongo db eveningschemadesignMongo db eveningschemadesign
Mongo db eveningschemadesignMongoDB APAC
 
Mongo db first steps with csharp
Mongo db first steps with csharpMongo db first steps with csharp
Mongo db first steps with csharpSerdar Buyuktemiz
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalorerajkamaltibacademy
 
MongoDB at FrozenRails
MongoDB at FrozenRailsMongoDB at FrozenRails
MongoDB at FrozenRailsMike Dirolf
 
Dev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBDev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBMongoDB
 
2016 feb-23 pyugre-py_mongo
2016 feb-23 pyugre-py_mongo2016 feb-23 pyugre-py_mongo
2016 feb-23 pyugre-py_mongoMichael Bright
 
Using MongoDB and Python
Using MongoDB and PythonUsing MongoDB and Python
Using MongoDB and PythonMike Bright
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.Emroz Sardar
 
Using MongoDB For BigData in 20 Minutes
Using MongoDB For BigData in 20 MinutesUsing MongoDB For BigData in 20 Minutes
Using MongoDB For BigData in 20 MinutesAndrás Fehér
 

Ähnlich wie 10gen MongoDB Video Presentation at WebGeek DevCup (20)

Dev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBDev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDB
 
Mongodb intro
Mongodb introMongodb intro
Mongodb intro
 
MongoDB: a gentle, friendly overview
MongoDB: a gentle, friendly overviewMongoDB: a gentle, friendly overview
MongoDB: a gentle, friendly overview
 
MongoDB and Ruby on Rails
MongoDB and Ruby on RailsMongoDB and Ruby on Rails
MongoDB and Ruby on Rails
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
MongoDB at RuPy
MongoDB at RuPyMongoDB at RuPy
MongoDB at RuPy
 
MongoDB Hadoop DC
MongoDB Hadoop DCMongoDB Hadoop DC
MongoDB Hadoop DC
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
OSDC 2012 | Building a first application on MongoDB by Ross Lawley
OSDC 2012 | Building a first application on MongoDB by Ross LawleyOSDC 2012 | Building a first application on MongoDB by Ross Lawley
OSDC 2012 | Building a first application on MongoDB by Ross Lawley
 
Mongo db eveningschemadesign
Mongo db eveningschemadesignMongo db eveningschemadesign
Mongo db eveningschemadesign
 
Mongo DB
Mongo DB Mongo DB
Mongo DB
 
Mongo db first steps with csharp
Mongo db first steps with csharpMongo db first steps with csharp
Mongo db first steps with csharp
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalore
 
MongoDB at FrozenRails
MongoDB at FrozenRailsMongoDB at FrozenRails
MongoDB at FrozenRails
 
Dev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDBDev Jumpstart: Build Your First App with MongoDB
Dev Jumpstart: Build Your First App with MongoDB
 
2016 feb-23 pyugre-py_mongo
2016 feb-23 pyugre-py_mongo2016 feb-23 pyugre-py_mongo
2016 feb-23 pyugre-py_mongo
 
Using MongoDB and Python
Using MongoDB and PythonUsing MongoDB and Python
Using MongoDB and Python
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.
 
MongoDB
MongoDBMongoDB
MongoDB
 
Using MongoDB For BigData in 20 Minutes
Using MongoDB For BigData in 20 MinutesUsing MongoDB For BigData in 20 Minutes
Using MongoDB For BigData in 20 Minutes
 

Mehr von WebGeek Philippines

Good Software Engineering Practices by Jesse Panganiban
Good Software Engineering Practices by Jesse PanganibanGood Software Engineering Practices by Jesse Panganiban
Good Software Engineering Practices by Jesse PanganibanWebGeek Philippines
 
WebGeek AppNimbus (Nikko Bautista)
WebGeek AppNimbus (Nikko Bautista)WebGeek AppNimbus (Nikko Bautista)
WebGeek AppNimbus (Nikko Bautista)WebGeek Philippines
 
Products = Mess - How to avoid it? By Suman Mukherjee
Products = Mess - How to avoid it?  By Suman MukherjeeProducts = Mess - How to avoid it?  By Suman Mukherjee
Products = Mess - How to avoid it? By Suman MukherjeeWebGeek Philippines
 
The Next Big Thing (Freelancer.com) - WebGeek DevCup
The Next Big Thing (Freelancer.com) - WebGeek DevCupThe Next Big Thing (Freelancer.com) - WebGeek DevCup
The Next Big Thing (Freelancer.com) - WebGeek DevCupWebGeek Philippines
 
The BlackBerry Opportunity at WebGeek DevCup
The BlackBerry Opportunity at WebGeek DevCupThe BlackBerry Opportunity at WebGeek DevCup
The BlackBerry Opportunity at WebGeek DevCupWebGeek Philippines
 
WebGeek DevCup Rules (At Pre-DevCup)
WebGeek DevCup Rules (At Pre-DevCup)WebGeek DevCup Rules (At Pre-DevCup)
WebGeek DevCup Rules (At Pre-DevCup)WebGeek Philippines
 

Mehr von WebGeek Philippines (11)

Good Software Engineering Practices by Jesse Panganiban
Good Software Engineering Practices by Jesse PanganibanGood Software Engineering Practices by Jesse Panganiban
Good Software Engineering Practices by Jesse Panganiban
 
Rules at #4SQHACKPH
Rules at #4SQHACKPHRules at #4SQHACKPH
Rules at #4SQHACKPH
 
Intro at #4SQHACKPH
Intro at #4SQHACKPHIntro at #4SQHACKPH
Intro at #4SQHACKPH
 
Theme at #4SQHACKPH
Theme at #4SQHACKPHTheme at #4SQHACKPH
Theme at #4SQHACKPH
 
Foursquare API + GoRated.PH
Foursquare API + GoRated.PHFoursquare API + GoRated.PH
Foursquare API + GoRated.PH
 
WebGeek AppNimbus (Nikko Bautista)
WebGeek AppNimbus (Nikko Bautista)WebGeek AppNimbus (Nikko Bautista)
WebGeek AppNimbus (Nikko Bautista)
 
Products = Mess - How to avoid it? By Suman Mukherjee
Products = Mess - How to avoid it?  By Suman MukherjeeProducts = Mess - How to avoid it?  By Suman Mukherjee
Products = Mess - How to avoid it? By Suman Mukherjee
 
The Next Big Thing (Freelancer.com) - WebGeek DevCup
The Next Big Thing (Freelancer.com) - WebGeek DevCupThe Next Big Thing (Freelancer.com) - WebGeek DevCup
The Next Big Thing (Freelancer.com) - WebGeek DevCup
 
The BlackBerry Opportunity at WebGeek DevCup
The BlackBerry Opportunity at WebGeek DevCupThe BlackBerry Opportunity at WebGeek DevCup
The BlackBerry Opportunity at WebGeek DevCup
 
WebGeek DevCup Theme
WebGeek DevCup ThemeWebGeek DevCup Theme
WebGeek DevCup Theme
 
WebGeek DevCup Rules (At Pre-DevCup)
WebGeek DevCup Rules (At Pre-DevCup)WebGeek DevCup Rules (At Pre-DevCup)
WebGeek DevCup Rules (At Pre-DevCup)
 

Kürzlich hochgeladen

[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdfSandro Moreira
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityWSO2
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Bhuvaneswari Subramani
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistandanishmna97
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusZilliz
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 

Kürzlich hochgeladen (20)

[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 

10gen MongoDB Video Presentation at WebGeek DevCup

  • 2. Release History •  First release – February 2009 •  v1.0 - August 2009 •  v1.2 - December 2009 – MapReduce, ++ •  v1.4 - March 2010 – Concurrency, Geo •  V1.6 - August 2010 – Sharding, Replica Sets •  V1.8 – March 2011 – Journaling, Geosphere •  V2.0 -- Sep 2011 – V1 Indexes, Concurrency
  • 3. Types of Non-Relational Data Models •  Key-value stores •  Document stores •  Column-oriented databases •  Graph databases
  • 4. What is MongoDB •  Document Store •  Horizontally Scalable •  High Performance
  • 5. MongoDB vs Traditional RDBMS server" schema" databases" coll ections " contain"tables"" documen ts" contain"rows" joins"
  • 6. Terminology RDBMS& Mongo& Table,"View" Collection" Row(s)" JSON"Document" Index" Index" Join" Embedded"Document" Partition" Shard" Partition"Key" Shard"Key"
  • 7. MongoDB is a Single-Master System •  All writes are to a primary (master) •  Failure of the primary is detected, and a new one is elected •  Application writes get an error if there is no quorum to elect a new master •  Reads can continue
  • 8. Consistency Models •  Relational databases support transactions •  Can only see committed changes •  Commits/aborts span multiple changes •  Read-only transaction flavors •  Read committed, repeatable read, etc •  Single vs Multi-Master
  • 9. Single Master •  All writes go to a single master and then replicated •  Replication can provide read scalability •  Writing becomes a bottleneck •  Physical limitations (seek time) •  Throughput of a single I/O subsystem
  • 10. Single Master - Sharding •  Partition the primary key space via hashing •  Set up a duplicate system for each shard •  The write-rate limitation now applies to each shard •  Joins or aggregation across shards are problematic •  Can the data be re-sharded on a live system? •  Can shards be re-balanced on a live system?
  • 11. MongoDB Storage Management •  Memory-mapped Database files •  Files are (pre)allocated as needed •  Indexes (B*-trees) point to documents
  • 12. Documents Blog Post Document" " p = { author: “sridhar”," date: new Date()," title: “Using the C# driver with MongoDB”," tags: [“NoSQL”, “Mongo”, “MongoDB”]}" " > db.posts.save(p)"
  • 13. Querying >db.posts.find()" " { _id : ObjectId("4c4ba5c0672c685e5e8aabf3")," author : “sridhar", " date : “Mon Jul 11 2011 19:47:11 GMT-0700 (PDT)", " title: “Using the C# driver with MongoDB”," tags: [“NoSQL”, “Mongo”, “MongoDB”]} " "
  • 14. Secondary Indexes Create index on any Field in Document" " // 1 means ascending, -1 means descending" " >db.posts.ensureIndex({author: 1})" " >db.posts.find({author: ʻsridhar'}) " " { _id : ObjectId("4c4ba5c0672c685e5e8aabf3")," author : “sridhar", " ... }"
  • 15. Query Operators •  Conditional Operators " •  $all, $exists, $mod, $ne, $in, $nin, $nor, $or, $size, $type" •  $lt, $lte, $gt, $gte" " // find posts with any tags " > db.posts.find( {tags: {$exists: true }} )" " // find posts matching a regular expression" > db.posts.find( {author: /^sri*/i } )" " // count posts by author" > db.posts.find( {author: ʻsridharʼ} ).count()"
  • 16. Atomic Operations •  $set, $unset, $inc, $push, $pushAll, $pull, $pullAll, $bit" > comment = { author: “fred”, " date: new Date()," text: “Interesting blog post”}" " > db.posts.update( { _id: “...” }, " " "$push: {comments: comment} );" "
  • 17. Nested Documents { _id : ObjectId("4c4ba5c0672c685e5e8aabf3"), " author : “sridhar"," date : “Mon Jul 11 2011 19:47:11 GMT-0700 (PDT)", " text : “Using the C# driver with MongoDB"," tags : [ “NoSQL", “Mongo", “MongoDB" ]," comments : [" "{" " "author : "Fred"," " "date : “Mon Jul 11 2011 20:51:03 GMT-0700 (PDT)"," " "text : “Interesting blog post"" "}" ]}"
  • 18. 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: ’Mongo’ } ) // geospatial index > db.posts.ensureIndex( “author.location”: “2d” ) > db.posts.find( “author.location” : { $near : [22,42] } )
  • 19. MongoDB – More •  Geo-spatial queries •  Require a geo index •  Find points near a given point •  Find points within a polygon/sphere •  Built-in Map-Reduce •  The caller provides map and reduce functions written in JavaScript
  • 20. Scaling MongoDB •  Replication - Read scalability •  Master/Slave •  Replica Sets •  Sharding – Read and write scalability •  Collections are sharded •  Each shard is served by its own replica set •  Shard key ranges are automatically balanced
  • 21. Write" Read" MongoS" MongoS" MongoS" MongoS" Key Range" Key Range" Key Range" Key Range" 0..30" 31..60" 61..90" 91.. 100" Primary" Primary" Primary" Primary" Secondary" Secondary" Secondary" Secondary" Secondary" Secondary" Secondary" Secondary"
  • 22. MongoDB Access •  Drivers are available in many languages •  10gen supported •  C, C# (.Net), C++, Erlang, Haskell, Java, JavaScript, Perl, PHP, Python, Ruby, Scala •  Community supported •  Clojure, ColdFusion, F#, Go, Groovy, Lua, R •  http://www.mongodb.org/display/DOCS/Overview+- +Writing+Drivers+and+Tools
  • 23. MongoDB Availability •  Source •  https://github.com/mongodb/mongo •  Server •  License: AGPL •  http://www.mongodb.org/downloads •  Drivers •  License: Apache •  http://www.mongodb.org/display/DOCS/Drivers
  • 24. download at mongodb.org We’re"Hiring"!" Engineers,"Sales,"Evangelist,"Marketing,"Support,"Developers"" conferences,"appearances,"and"meetups" http://www.10gen.com/events" " Facebook""""""""""|"""""""""Twitter"""""""""|"""""""""LinkedIn" http://bit.ly/mongoQ"" @mongodb" http://linkd.in/joinmongo" ©"Copyright"2010"10gen"Inc."
  • 25. Use cases and customers •  Use cases •  Case studies
  • 29. try at try.mongodb.org ©"Copyright"2010"10gen"Inc."
  • 30. download at mongodb.org We’re"Hiring"!" sridhar@10gen.com" @snanjund" conferences,"appearances,"and"meetups" http://www.10gen.com/events" " Facebook""""""""""|"""""""""Twitter"""""""""|"""""""""LinkedIn" http://bit.ly/mongoQ"" @mongodb" http://linkd.in/joinmongo" ©"Copyright"2010"10gen"Inc."