Ref: https://learn.cantrill.io/courses/1820301/lectures/41301583
R53 Health Checks - Key Concepts
-
đź”§Â Monitor and evaluate the health and performance of resources
-
3 Types:

- Endpoint health checks: assess the health of a specified endpoint (of a resource)
- State: healthy OR unhealthy
- Endpoint moves between the two states based on conducted checks
- Can be internal (AWS resource) or external
- Calculator health checks: evaluate application-wide health via status of other checks
- 💡 “Checks of checks”
- CW Alarm health checks: react to CW alarms (which are configured separately)
- e.g. for detailed in-OS or in-app checks if using CW Agent
-
Many of the advanced R53 routing policies are supported by R53 health checks
- đź”§Â DNS records can use R53 health checks to take decisions
- ‼️ Health checks are defined separately from DNS records, NOT within!
-
A fleet of health checkers is distributed globally:
R53 Endpoint Health Checks
Basic Configurations

- Endpoint can be specified by one of two options:
- IP address: perform health checks on given IP address
- Domain name: first resolve DNS name, then perform checks on retrieved IP address
- âť—Â IP address can differ depending on which health checker resolves the name
- Protocol configuration:
- TCP
- Endpoint healthy if (and only if!) TCP connection established successfully within 10 secs
- HTTP/HTTPS
- Endpoint healthy if (and only if!) BOTH these conditions apply:
- TCP connection established successfully within 4 secs
- Response sent with HTTP status code 2xx or 3xx within 2 secs after connecting
- 💡 More accurate than TCP check
Advanced Configurations

- Failure threshold
- Number of consecutive checks that must fail/succeed in order for health checker to change status of endpoint to unhealthy/healthy
- Gives robustness if endpoint is a bit unstable
- 💡 odd failed check will not influence health state
- String matching
- Increases accuracy of HTTP/HTTPS health checks
- Extra requirement for endpoint to be healthy:
- R53 checks response's HTTP status code plus response’s HTTP body (tries to match a given string)
- âť—Â Provided string must be found entirely in the first 5120 bytes of the response body
- Latency graphs
- Show how long endpoint took to answer