Lesson 23

DNS and Content Delivery

Amazon Route 53 and Amazon CloudFront

1. Amazon Route 53

Amazon Route 53 is a highly available and scalable cloud Domain Name System (DNS) web service. It translates domain names (like www.example.com) into numeric IP addresses (like 192.0.2.1) that computers use to connect to each other.

Core idea: Route 53 routes end users to internet applications by resolving names to IP addresses. It connects users to AWS infrastructure (EC2, ELB, S3) and also to resources outside AWS.

Key Features

  • Fully compliant with IPv4 and IPv6.
  • Domain name registration: Purchase and manage domain names directly through Route 53.
  • Health checks: Monitor the health of resources and route traffic to healthy endpoints.
  • Traffic flow: Visual editor to manage global routing with DNS failover for low-latency, fault-tolerant architectures.

Routing Policies

PolicyUse When
Simple routingSingle resource performing a function (e.g., one web server).
Weighted routingRoute traffic to multiple resources in proportions you specify (e.g., A/B testing: 75% to version A, 25% to version B).
Latency routingRoute to the Region providing the best (lowest) latency based on performance measurements.
Geolocation routingRoute based on the geographic location of users (localize content, restrict distribution).
Geoproximity routingRoute based on the location of resources, with optional bias to shift traffic between locations.
Failover routingActive-passive failover. Route 53 monitors the primary site and fails over to a backup if it becomes unhealthy.
Multivalue answerRespond with up to 8 healthy records selected at random. Not a load balancer substitute but adds availability.

DNS Failover in Action

A common pattern: primary record points to an ELB in front of EC2 instances. Secondary record points to a static S3 website. Route 53 health checks monitor the primary. If it fails, traffic automatically fails over to the S3 backup site.

Exam tip: You do not need to memorize all 7 routing policies, but know that failover routing gives active-passive HA, latency routing sends users to the fastest Region, and geolocation routing uses the user's location.

2. Amazon CloudFront

Amazon CloudFront is a fast content delivery network (CDN) service that securely delivers data, videos, applications, and APIs to customers globally with low latency and high transfer speeds.

Core idea: A CDN caches copies of content at edge locations around the world. When a user requests content, CloudFront delivers it from the nearest edge location, reducing latency.

Infrastructure

  • Edge locations: Worldwide network of data centers that serve popular content quickly.
  • Regional edge caches: Larger caches between origin servers and edge locations. Hold content that is not popular enough to stay at edge locations, reducing trips to the origin.

Benefits

BenefitDescription
Fast and globalMassively scaled global network of edge locations and regional caches.
Security at the edgeBuilt-in AWS Shield Standard, custom SSL via AWS Certificate Manager at no extra cost.
Highly programmableLambda@Edge runs custom code at AWS locations worldwide, closer to users.
Integrated with AWSDirectly connected to AWS Global Infrastructure. Works with S3, ELB, EC2, and Lambda.
Cost-effectivePay-as-you-go, no minimum commitments. Data transfer from S3/ELB to CloudFront is free.

Route 53 vs. CloudFront

Need to resolve domain names to IP addresses and route users based on geography or latency?Amazon Route 53 (DNS).

Need to cache and deliver content from the nearest edge location to reduce latency?Amazon CloudFront (CDN).

Need both? Use them together — Route 53 directs users to the best endpoint, and CloudFront caches content at the edge.

3. Quick Quiz

Test Your Understanding

Select one answer per question. You will receive immediate feedback.

1. A company wants to automatically route users to the AWS Region that provides the lowest network latency. Which Route 53 routing policy should they choose?
2. A website runs on EC2 instances behind a load balancer. The company wants to fail over to a static S3 website if the primary site becomes unhealthy. Which Route 53 feature enables this?
3. A company wants to test a new version of their application by sending 10% of traffic to the new server and 90% to the existing server. Which Route 53 routing policy should they use?
4. What is the primary purpose of Amazon CloudFront?
5. What is the relationship between CloudFront edge locations and Regional edge caches?
6. Which of the following is a benefit of Amazon CloudFront?
Progress: 0/6 correct (0%). Answer all questions to see the final recommendation.
Primary Source: AWS Academy Module 5: Networking and Content Delivery (module-5.txt), Sections 5-6. AWS Global Accelerator referenced in Module 4 (module-4.txt).
Ask your teacher: If you confuse the Route 53 routing policies or need more on how CloudFront reduces latency, ask. The exam often asks which routing policy to use in a given scenario.
Last updated: June, 2026© 2026 Shahriar Ahmed ShovonCredits