preloader

No, You Don't Need a Load Balancer

images/charts.jpg
By J. Toman / on 17 Oct, 2021

Who This is Not For

If you work for a Fortune 500 company, do more than $500,000/yr in B2C sales through you website, or are otherwise in the top 2% of websites as measured by traffic, this article is not for you. This article is for the other 98% of website owners or business owners that are finally getting around to putting up a website, or have a small site on one server.

What The Heck is a Load Balancer?

A load balancer is a piece of networking hardware or software that acts like a traffic cop. It sits in front of your web servers, plural, and directs which server will handle which request from a visitor. It “balances the load” onto all the servers evenly so no one server is doing all the work while the others are sitting idle. It can also detect if one of the servers has crashed, and take it out of the line up of servers that it sends traffic to. If you are running your website or application on more than one server, it’s an essential tool.

graph TD Z((Internet)) --> A[Load Balancer] A -->| traffic | B(Web Server 1) A -->| traffic | C(Web Server 2) A -->| traffic | D(Web Server 3)

Why Don’t I Need One?

Here are a few good reasons you don’t need a load balancer:

  1. Because you don’t have webservers, plural. You only have one webserver and it’s not running at 100% or even 50% all the time.
  2. Because like most small websites you only see ~1000 unique users a month. If you do ecommerce you spike up to maybe ~3000 uniques on Black Friday or Cyber Monday. That’s about it for traffic.
  3. Because more moving parts means more things that can break.
  4. Because more moving parts means more things you need to pay for, both for leasing the actual load balancer and for maintaining it.

But Everyone Else Says…

Everyone else is trying to sell you stuff. I don’t mean that rudely. They sincerely believe it would be in your interest to be able to suddenly scale up to tens of thousands of hits per second. They believe this because it’s cool technology and most IT engineers have never seen technology or innovation they didn’t like. Bigger is better, always.

I’m sure you’ve seen this yourself. A website that you often visit suddenly changes its user interface in a way that makes all the work you put in to learn the old interface useless. Perhaps they have added some features, but you honestly can’t think of a use for those features or if you can the feature is used so rarely that it’s hardly worth rebuilding the entire interface to support it. Sound familiar? The reasons this happens is that software engineers are like beavers: they are fundamentally unable to stop building, even when what they have does exactly what is needed and no more. Every software project I have ever seen or worked on reached a point where it was feature complete…and then it kept adding features no one ever requested. That’s just the nature of developers.

This phenomena also manifests itself in the form of “Can you build it any bigger?” system architecture. A simple little website suddenly needs 99.999% uptime, even if it doesn’t have an ecommerce store. So now that means you need

  1. A load balancer
  2. Multiple servers
  3. Multiple redundant database servers
  4. A virtual private cloud VPC so that all these machines can talk to each other securely
  5. An internet gateway to act as a firewall between the Internet and your VPC
  6. And a bastion host so you can get into your VPC to manage all the moving parts that have been shoved in there.

But once all that is done, your little website is still only getting ~1000 users a month, and most of your servers are sitting idle. Your servers are sitting idle, but your hosting charges are racking up quite nicely. Ouch.

OK, So What Do I Need?

For the vast majority of sites, all you need is either a simple virtual server running a content management system CMS, or a static website hosted in cloud storage like AWS S3, Netlify, or Fleek, and a Content Delivery Network to sit between your visitors and your site. The CDN takes most of the load for your traffic, and the CMS just acts to feed the CDN when you add or modify content. Simple, few if any moving parts to fail, not much maintenance required.

Load balancers have their place in the toolbox of web application development, but for most sites with modest traffic, they are just overkill that add more problems than they solve.