Thursday, February 16, 2012

Working notes on cloud-based MongoDB with python

I've been thinking about getting into mongoDB for a good while.  I'm looking for a platform that works, scales, and integrates with python with a minimum of hassle.  Cheap would be nice too.

Tonight, Google and I sat down to do some nuts and bold research.  Here are my notes.  Have anything to add?

PS - Based on what I found, I'm thinking Heroku + MongoLab + PyMongo + Django is probably the best way to get my feet wet, since I'm already comfortable with django and heroku. 

I'll be trying this in the near future -- will let you know how it goes.

Cloud hosts for mongoDB:
  •     MongoLab
  •     MongoHQ
  •     MongoMachine -- bought by MongoHQ

Reviews here say MongoLab > MongoHQ w.r.t customer service

python ORMs for mongo
  •     mongonaut
  •     mongoengine
  •     mongokit/django-mongokit
  •     pymongo (simple wrapper, no ORM)
  •     ming
  •     django-mongodb
  •     django-nonrel

Strong recc for mongoengine > mongokit, esp for django developers.

Says mongoEngine is faster than mongoKit

Slides also argue for mongoEngine

Says that pyMongo > mongoEngine

mongoNaut is clearly not mature -- off the island!

Instructions for setting up django and mongo, if that's your thing

PyMongo documentation

MongoLab's example of integration, plus a small amount of stackoverflow chatter about it.

Decision reached!
    Heroku + MongoLab + PyMongo


  1. Abe,

    Good stuff, but I have an unrelated question: What python libraries do you use to scrape websites?

    I need to click on some buttons, follow some links, parse (sometimes ugly) html, and convert html tables to csv files.

    Is mechanize the way to go for browsing operations? What's your take on BeautifulSoup vs. lxml vs. html5lib for parsing? Should I definitely learn xpath?

    Any advice would be much appreciated (but this can wait until you see me in the CAP lab, of course).



  2. Thanks for sharing this such a great information.I really appreciate your work i share this link to my facebook friend as well as Digg and twitter this info helps to everyone.

    Cloud Control I Managed Cloud Solutions