Earlier this week, I wrote about how we designed the database for PollGab.com. Because we went with AWS DynamoDB for the database storage and AWS Lambda for the processing work, costs are really, really low:
That is not a typo: that’s $1.85 USD.
Richie puts the business logic in functions, and those functions run in AWS Lambda. That’s the compute power, or what used to be known as an application server. It was completely free last month because Amazon gives you the first 1,000,000 requests totaling less than 3.2M seconds of compute time (889 hours, aka 37 days) free of charge. We’re in the free tier for data transfer and email services as well.
We spent $0.04 on Amazon S3, aka file storage. I honestly don’t remember what we’re putting in file storage, and at four cents, I’m not gonna bother to look.
Scrolling on down to page 2 of the bill:
The free tier of DynamoDB includes up to 25GB data and enough capacity to handle about 200 million well-written queries per month. My kind of database right there.
The most expensive thing in our hosting bill is $1.01 for Route 53, which is DNS. When you type pollgab.com into a web browser, DNS is the magical service that tells your browser where to go.
This incredibly exorbitant pricing is due to the fact that each domain costs $0.50 per month, and we have two domains. ¯\_(?)_/¯ We’ll have to learn to live with that expense.
Next up is $0.74 for CloudWatch, which is monitoring. Yes, that’s right: monitoring is 5-6x the cost of the rest of our infrastructure combined, hahaha. Upon reading that, my first reaction was, “I have to stop what I’m doing and check CloudWatch’s settings.” After spending approximately $0.74 worth of my time, I realized that I was already sidetracked because we were getting write alerts in the dev environment. I abandoned that task.
So why does PollGab cost $59 per year?
Well, the hosting part is doggone near free, but the development costs certainly are not.
Building a cloud-native application is about spending more development time up-front in exchange for lower long-term costs of ownership – both lower hosting costs, and lower systems administration costs. By himself, Richie’s been able to crank out PasteThePlan, SQL ConstantCare®, and PollGab.com and more over the last few years, and we haven’t had to hire sysadmins or support teams.
The hosting costs on these do indeed go up as they become more popular – but as they gain more paying customers, it’s much easier to get apps like this to become profitable, and keep them that way. That’s where cloud-native pays off.