• Like

Loading…

Flash Player 9 (or above) is needed to view presentations.
We have detected that you do not have it on your computer. To install it, go here.

A few questions on MongoDB

  • 993 views
Uploaded on

 

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
993
On Slideshare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
3
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. @ IPRUG What is mongoDB?
  • 2. @ IPRUG What is a Document Oriented Database?
  • 3. @ IPRUG {"IPRUG": { "tagline": "The source of all things Ruby in Suffolk", "website": "http://www.iprug.org", "members": [ {"name": "MrJaba", "role": "foolhardy organizer", "presentations" : ["higher order ruby", "websockets"]}, {"name": "KerryB", "role": "foolhardy presenter"} ] } } A Document
  • 4. @ IPRUG How do you use it? Part 1.
  • 5. @ IPRUG How do you use it? Part 2. 1. Connect: db = Mongo::Connection.new.db("mydb") 2. Insert a document: coll = db.collection("RUGS") iprug = { "IPRUG" => {"tagline" => "The source of all things Ruby in Suffolk", "website" => "iprug.org" } } coll.insert(iprug)
  • 6. @ IPRUG How do you use it? Part 3. 3. Updating: iprug["tagline"] = "Suffolk haz Ruby!" coll.update({"_id" => iprug["_id"]}, iprug)
  • 7. @ IPRUG How do you use it? Part 4. 4. Find all: coll.find() 5. Conditions: coll.find("tagline" => "Suffolk haz Ruby!") 6. Range Queries: coll.find("value" => {"$gt" => 20, "$lte" => 30}) 7. Regex queries: coll.find( {"tagline" => /^Suffolk/} )
  • 8. @ IPRUG ORM Tools? * MongoMapper * Mongoid * Mongomatic * MongoDoc * MongoModel * Candy
  • 9. @ IPRUG Is it In Memory?
  • 10. @ IPRUG Can it be written to disk?
  • 11. @ IPRUG What if my server crashes?
  • 12. @ IPRUG So I'm going to lose all my data?
  • 13. @ IPRUG What about Replication?
  • 14. @ IPRUG What about Performance?
  • 15. @ IPRUG Why would I use this over MySql?
  • 16. @ IPRUG Why Wouldn't I use MongoDb?
  • 17. @ IPRUG References Durability : http://www.mikealrogers.com/2010/07/mongodb-performance-durability/ Their Rebuttal: http://blog.mongodb.org/post/381927266/what-about-durability Durability Guide: http://www.thebuzzmedia.com/mongodb-single-server-data-durability-guide/ Performance: http://www.eggheadcafe.com/tutorials/aspnet/6f573869-c8eb-40c3-9946-2f61e0163966/mongodb-vs-sql-server-basic-speed-tests.aspx http://prajwal-tuladhar.net.np/2009/11/15/500/mongodbs-performance-as-compared-to-others-esp-couchdb/ NoSQL Overview: http://bjclark.me/2009/08/nosql-if-only-it-was-that-easy/