Serving a billion web requests with boring code
notes.billmill.org
notes.billmill.org
When we were going through due diligence as part of being acquired by a large tech company, I had to answer a lot of questions about our infrastructure and to "prove" that our boring tech stack could actually achieve this.
That "stack" was 3 pods (2 in one AWS region, 1 in another) comprised of 4 Linux boxes and 3 Windows boxes.
In a stack, Linux boxes were 2 monitoring servers and 2 app servers running an OSS SW package, while the Windows boxes were two app servers running our .NET APIs, and a SQL server.
Fail over was handled by SQL cluster at DB level and ELB at the app level.
While the stack and code were boring, a lot of work went into performance, reliability, and observability.
After we were acquired, my new infra budget was based on their own modeling for scale, resulting in a monthly AWS budget that was 10X my previous annual budget.
With hindsight, I’m curious which of the other choices made would have changed the most with a multi page architecture, and have you discovered a cleaner way of avoiding it? Struggling with something similar at the moment.
There's nothing boring about this, it's unfortunate that they took to name this "boring code".
Aside from this, the actual implementation details are quite interesting and worth a read. A better title would be "lessons learned using a modern stack for healthcare.gov"
vis: "The Complicators Gloves" https://thedailywtf.com/articles/the_complicator_0x27_s_glov... ... I can imagine co-workers (past and present) who would have tried to add more complexity.
`grpc` is a bit fancy (compared to `curl *.json`), which he admits to, but is also fairly battle-tested / boring, and gets some extra benefit of schema + performance. Maybe swagger or something would have been more "boring", but also veers a little away from "the default golang stack".
At ad hoc in 2018, using go/react/rds/ec2 was a pretty standard stack that I could be sure my coworkers would have no trouble getting up to speed with.
React was only 5-months old, and Go was only 4-years old, when healthcare.gov was launched.
First released:
- Go (Nov 2009)
- React (May 2013)
- Healthcare.gov (Oct 2013)
https://en.m.wikipedia.org/wiki/Go_(programming_language)
https://en.m.wikipedia.org/wiki/React_(JavaScript_library)
https://en.m.wikipedia.org/wiki/HealthCare.gov
EDIT:
I missed this in the article:
> There are many valid criticisms of react; this piece is an example, and I was aware of the issues already in 2018 when I was building the site.
Go in the healthcare.gov context that Paul Smith used it was indeed an innovation token; they were in a dire situation at that point.
5MM a day is 150MM a month.
Is this a year? That's 1.3B
I generally measure the per second rate. Per millisecond can be mathed quick enough for conversational calculations.
5 million a day was a normal weekday non-open-enrollment request number; it was much higher during open enrollment but I no longer have the stats.
Very interesting post, thanks for sharing.