Lean and mean MongoDB

1,910 views

Published on

Why MongoDB is a good fit for startups.

0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,910
On SlideShare
0
From Embeds
0
Number of Embeds
142
Actions
Shares
0
Downloads
10
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Lean and mean MongoDB

  1. 1. Lean and mean MongoDB or why MongoDB is good for start ups
  2. 2. /whois olegp
  3. 3. /whois olegp● doing startups since 2000 – RIOT-E● tech DD for investors since 2008● Startup Sauna coach● new venture: StartHQ
  4. 4. Web apps 101
  5. 5. Web apps 101● REST API centric design● One primary data store – Except blobs● No premature optimization – e.g. caching
  6. 6. The Contenders
  7. 7. Background Reading● “How FriendFeed uses MySQL to store schemaless data” – “mariadb dynamic columns”● “PostgreSQL as a schemaless database”
  8. 8. The Pros
  9. 9. The Pros● Simpler schema design – Fewer many to one relationships – Design is part of development, not separate● No DB setup step● No DB migrations *● No ORMs● JSON as query language
  10. 10. Hosting● Amazon RDS: from $18● Heroku Postgres: from $10● MongoHQ & MongoLab: from FREE
  11. 11. Database as a Service
  12. 12. Database as a Service● Web admin FTW – Saves you building your own● No SSL – But on AWS you cant sniff traffic● Expensive backups – But you can easily roll your own
  13. 13. Some Codereturn db.getCollection("apps").find({ nameLowerCase:{ $regex:utils.prettify(request.queryParams.term) }, verified:true}, { name:true, url:true}).sort({extractors.social.score:-1}) .limit(10).toArray().map(function(app) { return { label:app.name, value:app.url };});
  14. 14. Tools● 10gen MMS● Metrica● Nodetime
  15. 15. Getting Started
  16. 16. Getting Started● try.mongodb.org● “dailyjs lmaw”● olegp/notes & olegp/tokenize
  17. 17. Summary● Optimize for ease of development● Do design your schema● Do not prematurely optimize● Have fun!
  18. 18. Thanks! @olegpodsechinstarthq.com/apps/?q=mongodb

×