I have an ongoing goal of creating many subscription web applications in 40 hours. If 500 Startups’ goal is to fund many startups with micro funding, my goal is to create many small startups with little time.
I try to meet these criteria when creating those web applications:
- It should reside on as much free infrastructure as possible.
- It should be ready to scale in case it takes off.
- It should be revenue generating from day 1.
- It should be designed to support thousands of simultaneous users.
- It should require minimum maintenance from me. Once it’s live, it should keep on going.
I have a very strong opinion on the stack. Here’s what I’d go for:
Heroku for the cloud server infrastructure
Absolutely Heroku. I wouldn’t go with anything else right now. It’s a joy to use once you figure it out. It has a free tier which is very performant for websites that are not busy yet. It can be scaled with one command. It has easy-add add-ons like memcache when you need to scale. It uses Git for deployments. It monitors the app and brings up a new one if any instances crash.
Postgres on Heroku
No matter how awesome NoSQL is, I still need the ability to query and sort structured data. I try to use a combination of NoSQL (to store large data) and Postgres (only for light data that needs sorting and querying).
Postgres on Heroku is absolutely the way to go. It’s managed so I don’t have to do upgrades, maintenance etc. It has a bunch of common utilities like making snapshots and backups, cloning, etc. I don’t have to worry about underlying physical hardware. Win.
And I have lots of experience with Postgres and I know it can handle millions of rows with no problems.
Beware of using one-schema-per-customer though. That is Postgres’ Achilles heel. It dies under the weight of hundreds of schemas. Backups and restores take 10 hours or more. Even Heroku says don’t do it!
For the NoSQL layer, I like DynamoDB. It is very fast both from my local machine as well as from Heroku (Heroku uses Amazon US East – Virginia fyi). I trust Amazon’s cloud infra. They use it internally and since it powers Amazon surely it can power my little app.
I like creating a single-page app. You completely remove all the headache of passing data back and forth between pages.
Yes you do have to deal with some History/back/forward button issues but only once. You also have to deal with dynamically loading resources if your app gets big. But after that it’s single-page nirvana.
Build server-side services as REST API and use them via your front-end
It is no more difficult to build your server-side services as REST APIs. You may as well do so. This way you can easily open up the API in the future. Plus it makes a lot of sense.
Server-side language: Java
App Server: Tapestry
This is not the most ideal app server. I was actually looking for something far more lightweight than Tapestry. For some reason I thought Tapestry was that light-weight solution. But it’s definitely doable for me. Key features: It uses Java. It has nice injection framework. It’s use of Maven and the Maven Repository is wonderful. Adding new modules is so easy.
Maven as a build tool is great, especially with Tapestry. Heroku for Java kinda needs it too. I just really like how easy it is to add new modules and then deploy to Heroku.
I especially like how I can push to GitHub to commit and then push to Heroku to deploy.
I really, really like the above web app stack. Cost effective, time effective, and ready to scale.