MongoHQ is a database-as-a-service provider and is independent of Heroku. That's both good and bad. The good part is that I can change my database supplier without changing Heroku. The bad part is that I'm worried about performance of access between Heroku and MongoHQ. Just a worry, nothing concrete.
From an application architecture things are bit cleaner for me. I generate file-based reference data on my local system and push it into MongoDB for use by the application. My picture now looks like:
Setting it up
Being cheap, I wanted to start with the free MongoHQ sandbox. Initially I tried using the "heroku addons:add ..." command line. That failed as I'm using the free Heroku for development and it wanted my account to have a credit card on file. IMO, if someone doesn't have my credit card number, I can't accidentally do something that results in charges to my account.
So I went directly to MongoHQ and got my account set up. Even there, it looked like they wanted a credit card until I noticed the tiny link saying "skip this and get a free version". That worked and I got my first database.
I had an initial point of confusion. My database was created but I didn't have a username/password with which to access it. I navigated to the database, went to the admin tab and added a user. That worked and I could access the DB via my local mongo console.
Larry,
ReplyDeleteGreat post on getting started. Pretty simple uh?
I've been with MongoHQ for 2 years now, and I am answering your question "I'm worried about performance of access between Heroku and MongoHQ."
As long as you run a shared plan **not** marked "EU", then you are running in Amazon US-East-1. Heroku also runs in US-East-1. You are getting the lowest latency the best performance you can on the AWS platform - aside from running a single host with the db and application server.
Go forth and conquer!