I see in aws-cdk there are two constructs:
Each have different props that do not look compatible with each other.
I'm wondering which one to use?
Both cloudfront and Route53 have different purpose. Route 53 is a DNS service whereas Cloudfront is CDN service to serve static (and dynamic) content. You can use the cloudfront with Route 53 Geolocation Routing .
S3 stores all the pre-recorded videos in different formats. CloudFront is used to cache the video to edge locations. This can be used to deliver content to the end user. Location is picked up automatically based on the closest physical edge location.
CloudFront delivers your content through a worldwide network of data centers called edge locations. When a user requests content that you're serving with CloudFront, the request is routed to the edge location that provides the lowest latency (time delay), so that content is delivered with the best possible performance.
CloudFront offers several options for streaming your media to global viewers—both pre-recorded files and live events. For video on demand (VOD) streaming, you can use CloudFront to stream in common formats such as MPEG DASH, Apple HLS, Microsoft Smooth Streaming, and CMAF, to any device.
The AWS CloudFrontWebDistribution
is the original method for working with CloudFront distributions. But now, they had implemented a new method that is provided by Distribution
. You can use both CloudFrontWebDistribution as well as Distribution for working with CloudFront distributions, but Distribution
has a simpler interface and they receive new features faster. So, it is recommended to use Distribution
instead of CloudFrontWebDistribution
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With