Menu Close

Chapter 11(1/4) – Storage and Content Delivery

Amazon CloudFront – AWS CDN

AWS Storage Gateway – A service connects on-premises appliances to cloud-based storage

Amazon CloudFront

A global Content Delivery Network (CDN) service

  • A globally distributed network of caching servers that speed up the downloading of web pages and other content
  • use DNS geo-location to determine the geographic location of each request for a web page or other content, then they serve that content from edge caching servers closest to that location instead of the original web server.
  • supports all content that can be served over HTTP or HTTPS

To start using:

  1. Create a distribution, which is identified by a DNS domain name.
  2. To server files from CloudFront, use the distribution domain name in place of your website’s domain name.
  3. The rest of file paths stay unchanged
  4. Create a CNAME record in your DNS service, the CNAME is automatically redirected to your CloudFront distribution domain name

Origins – When you create a distribution, you must specify the DNS domain name of the origin – the S3 bucket or HTTP server from which you want CloudFront to get the definitive version of your objects

Cache Control

Once requested and served from an edge location, objects stay in the cache until they expire or are evicted to make room for more frequently requested content.

  • By default, objects expire from the cache after 24 hours
  • To control how long objects stay in CloudFront cache before expiring, use Cache-Control headers set by your origin server or set the minimum, maximum and default Time to Live TTL for objects in your CloudFront distribution
  • To remove copies of an object from all CloudFront edge locations, call the invalidation API
  • Instead of invalidating objects manually, best practice is to use version identifier as part of the object file path name

Amazon CloudFront Advanced Features

  • Dynamic Content
  • Multiple Origins
  • Cache Behaviors – to control which requests are served by which origin and how requests are cached

The functionality you can configure for each cache behavior:

  • The path pattern
  • Which origin to forward your requests to
  • Whether to forward query strings to your origin
  • Whether accessing the specified files requires signed URLs
  • Whether to require HTTPS access
  • The amount of time that those files stay in the Amazon CloudFront cache

Use cases

  • Serving the Static Assets of Popular Websites
  • Serving a Whole Website or Web Application
  • Serving Content to Users Who Are Widely Distributed Geographically
  • Distributing Software or Other Large Files
  • Serving Streaming Media

Inappropriate use cases using CloudFront:

  • All or Most Requests Come From a Single Location
  • All or Most Requests Come Through a Corporate VPN

AWS Storage Gateway

A service connects on-premises appliances to cloud-based storage.

  1. Install the AWS Storage Gateway software appliance VM on a host in your data center, register with your AWS account through AWS management console
  2. The storage associated with the appliance is exposed as an iSCSI device that can be mounted to the on-premises applications

3 configurations for AWS Storage Gateway

Gateway-Cached Volumes

  • Expand your local storage capacity into S3
  • All data stored on a Gateway Cached volume is moved to S3
  • Recently read data is retained in local storage to provide low-latency access

Gateway-Stored Volumes

  • Data is stored on on-premises storage and asynchronously back up to S3
  • Provides low latency access to all data, while backup to S3

Gateway Virtual Tape Libraries (VTL)

  • Leverage your existing tape-based backup application infra to store data on virtual tape cartridges that you create on you Gateway-TTL
  • Data is archived on a Virtual Tape Shelf VTS and stored in Amazon Glacier

Leave a Reply

Your email address will not be published. Required fields are marked *