AWS is Amazon’s cloud service, similar to Microsoft’s Azure. It offers cloud based architectures such as Infrastructure as a Service (IAAS), Platform as a Service (PAAS) and Software as a Service (SAAS).
This very website is hosted on AWS, but isn’t stored on an EC2 instance or Beanstalk (AWS’s typical web hosting platforms) it is indeed hosted in a S3 bucket, usually reserved for file storage.
The S3 bucket is accessed by Amazon’s Cloudfront infrastructure, this acts as a gateway from the internet into the AWS network. Cloudfront works by caching the website files that are accessed and stroing them at edge locations worldwide. This mean that although this site is stored in the Ireland datacentre, if you access it from the US you will be actually seeing the files that are cached on Amazon’s servers in the US – giving much faster response times. Cloudfront is what is known as a Content Delivery Network (CDN) provider.
When you request www.mikeparker.co.uk your web client does a Dynamic Name Service (DNS) lookup for the IP address of the domain. mikeparker.co.uk uses AWS’s Route 53 which is Amazon’s DNS server. This allows Amazon to target the correct IP to return to the client based on geographical location, allowing you as the visitor to access the closes CloudFront edge server to your location.
The first time an edge server needs to return the site it downloads a copy from the S3 bucket and caches it locally. This cache is usually refreshed every day, but this can be adjusted on an instance by instance basis.