AWS Route 53 Routing Policies explained with diagrams

Reading time: 5 minutes

Wait, route what? Yes you are reading that correctly. AWS (Amazon Web Services) Route 53 is DNS (Domain Name Services). In this post I’ll be writing about AWS Route 53 Routing Policies and not discussing what is DNS. Search elsewhere for that information. Keep in mind these diagrams are simplified.

What is Route 53?

Again Route 53 is a DNS service built and fully managed by AWS. Did you know Route 53 has a freaking 100% SLA?! Read here if you don’t believe me. It basically means it will NEVER, ever be down! I don’t know about you but that’s beyond amazing to me! Here’s a link to learn more in depth about Route 53. Why 53? 53 is the common DNS port.

Route 53 Routing Policies

Simple

This is the default routing policy. Use this only when you have exactly one resource such as one EC2 web server. This policy can contain multiple values but it returns one resource. This policy is not recommend for production sites.

AWS Route 53 routing policy simple diagram

Failover

Allows creating two records for the same name. This starts like simple policy but with a health check. If that single web server is unhealthy then you can point elsewhere. That next pointer can be another web server or possibly an error.html page hosted in AWS S3.

AWS Route 53 failover routing policy diagram

Geolocation

Use this when you want to serve your site based on the location of the client or user.

AWS Route 53 geolocation routing policy

Geoproximity

This is somewhat complicated so I would like to point to original documentation for full explanation.

Let’s subscribe to learn more or suggest topics!

Post NotificationsGet the latest post directly in your inbox!

Latency

When you have multiple resources in multiple regions, this policy routes the user not to the closest resource necessarily but the resource who responds the fastest or lowest latency.

AWS Route 53 latency policy diagram
In this example we can see the latency from France to United States was the lowest so therefore the website traffic is routed from a U.S region and not from an Australian region.

Multivalue answer

This one lets your return multiple values for each of your resources. The client or user browser randomly chooses one. Optionally you can add health checks. If any value becomes unhealthy then the client chooses another value to resolve. This is not an alternative solution to load balancing, it’s an enhancement.

AWS Route 53 multivalue answer routing policy diagram

Weighted

This one is fantastic for new deployments or release testing new versions. It’s based on a numerical value ranging from 0 to 255. If you specify a value of 0 for all regions then it’s routed equally.

AWS Route 53 weighted routing policy
The math is a little more complicated than simplified here but you get the idea. Over time if release 2.0 is going good, then you would increase that value and lower release 1.0.

In the future I’ll be showing how to actually implement these via code. Subscribe to get notified when that gets released!

As always if you see any errors or mistakes, please comment below. Don’t forget to like, share, and subscribe for more! 🙂

Post NotificationsGet the latest post directly in your inbox!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Up ↑

Discover more from The Cloudly Engineer

Subscribe now to keep reading and get access to the full archive.

Continue reading