What Is A CDN?
A CDN is a content delivery network and refers to a distributed group of servers which work together to provide extremely fast delivery of Internet content. You might have heard about CDN’s when it comes to Cloudflare and its outage on July 2nd, 2019. Cloudflare serves quite a few functions but one of its main functions is as a gigantic CDN. Another very large CDN is Cloudfront which is offered by Amazon. In fact, this website is served to you via Cloudfront. It’s assets are stored on S3 which is Amazon’s object store and then served from S3 via Cloudfront to the end user.
By using a CDN we can confidently trust that our content will be delivered reliably and can scale if we have any large spikes in traffic. Good CDN’s will also help protect against DDoS attacks.
A lot of times if you’re quickly getting started (for example react) with a package in web development it’ll have reference to an external way to load the package so you don’t have to download it locally:
You’ll notice that it refers to unpkg.com. unpkg.com as you might have guessed is a CDN for npm. We’re interacting with CDN’s all the time even if we may not realize it, so that’s why when a CDN goes down or has outages (which is very rare) it feels like the entire Internet is down.
Read more about CDN’s here