Separate origins and different auth methods

With this scenario, we'll set up two separate property hostname to edge hostname associations ("property hostnames") to field requests to separate origins. We'll streamline delivery from each by using unique Origin Characteristics and Content Characteristics.

Overview

We'll be fielding requests to two property hostnames to deliver image file content that is hosted on two separate origin servers. It assumes that these requests are originating from one of two URLs:

  • https://quick-images-hi-res.com. A user targets this URL to request high-resolution ("hi-res") image content.
  • http://quick-images-lo-res.com. A user targets this URL to request low-resolution ("lo-res") image content.

The lo-res images are hosted on NetStorage and will be accessible via HTTP requests. The hi-res images are hosted on a Google Cloud Platform origin and require secure, Standard TLS authentication.

Phase 1: Create the property hostnames

We need a new Object Delivery property with two property hostnames. We want to employ Standard TLS security (HTTPS) access for the hi-res content, and standard HTTP access for the lo-res content.

The steps that follow outline what you need to do to create the property hostnames for this scenario.

  1. You need a Standard TLS certificate set up for the quick-images-hi-res.com hostname. This can take a while to provision, so you should create it before you create the Object Delivery property. You need to include the hostname as a certificate name (CN) or subject alternate name (SAN) in the certificate.

  2. Create a new Object Delivery property in ​Akamai Control Center​.

  3. Set up a secure (Standard TLS) hostname for quick-images-hi-res.com.

  4. Set up an unsecure hostname for quick-images-lo-res.com.

Phase 2: Add a new rule for the lo-res image requests

For download requests to http://quick-images-lo-res.com, we want to ensure that low-res images are served from the proper origin and optimized for delivery. So, we incorporate a separate rule to target requests for that URL, and to use specific Origin Characteristics and Content Characteristics behavior settings.

  1. In the Property Configuration Settings click Add Rule.

  2. Ensure Blank Rule Template is selected (default) and click Insert Rule.

  3. Click the gear icon in the New Rule and select Edit Name. Set this to "Lo-res NetStorage" for this scenario and press Enter.

  4. Click Add Match and set the fields as follows:

    • Hostname
    • is one of
    • Select Items. Click this field and input the property hostname for the lo-res images, quick-images-lo-res.com.

Add behaviors to this rule

Add these behaviors to the new rule and configure them accordingly.

Add the Origin Server behavior

First, we'll add this behavior to configure the origin server that's hosting the software patch.

  1. Click Add Behavior.

  2. Type origin in the Search available behaviors field to filter results, select Origin Server, and click Insert Behavior. Set the options in this behavior as follows:

    • Origin Type: NetStorage

    • NetStorage Account: Click to select the NetStorage account associated with the storage group that houses the lo-res images.

Add the Origin Characteristics behavior

Next, add this behavior to optimize delivery from your origin, based on its configuration.

  1. Click Add Behavior.

  2. Type origin in the Search available behaviors field to filter results, select Origin Characteristics, and click Insert Behavior. Set the options in this behavior as follows:

    • Origin Location. Set this to the geographic location that represents the NetStorage account you set in the Origin Server behavior.

    • Authentication Method. ​Akamai​ Origins - Auto, Others - None

Add the Content Characteristics behavior

Now, we'll add this behavior to optimize delivery based on the type of content we're delivering.

  1. Click Add Behavior.

  2. Type content in the Search available behaviors field to filter results, select Content Characteristics, and click Insert Behavior. Set the options in this behavior as follows:

    • Origin Object Size. These are low-resolution images, so they're all Less than 1MB.

    • Popularity Distribution. We're not sure of the popularity, so set this to Unknown.

    • Catalog Size. This is the overall size of the lo-res image catalog. The entire catalog of images is less than 1TB in size, so set this to *Medium.

    • Content Type. Set this to Images.

Phase 3: Configure the Default Rule for the full installable

In this scenario, the majority of the requests will be coming for hi-res images. So, we'll configure the Default Rule to handle these requests. We need to set the Origin Server as "Your Origin" to incorporate Google Cloud Platform as the origin and then apply settings in other use case-based behaviors to optimize delivery from this origin.

Configure the Origin Server behavior

For this scenario, set this to Your Origin. Configure settings here for a Google Cloud Provider origin. See the Third-party origin prerequisites topic in the Property Manager help.

You can add Cloud Interconnects for Google Cloud (GCP)

You might want to add this behavior to the Default Rule to maximize traffic flow through the private network interconnects (PNIs) that GCP origins use.

This won't impact requests for the lo-res images. We've already configured a separate rule for these and specified their NetStorage origin in that rule.

Configure the Origin Characteristics behavior

Set these options as follows:

  • Origin Location. Set this to the geographic location that best matches the location of "Your Origin."

  • Authentication Method. For this scenario, we'd select Google Cloud Platform.

You can find details on the remaining options for this behavior in Origin Characteristics & Object Delivery.

Configure the Content Characteristics behavior

The following points apply to the hi-res images, so set these options, accordingly:

  • Origin Object Size. The hi-res images are larger than 1MB but not larger than 10MB. So, this is set to 1-10MB.

  • Popularity Distribution. This is the most popular content, but it doesn't specifically fall into either of the two use cases. So, set this to Other.

  • Catalog Size. This is the overall size of the high-res image catalog. The catalog is more than 1 TB in size, but not larger than 100TB. So, set this to Large.

  • Content Type. We'd set this to Images.

What happens next?

First, you need to complete creation of the Object Delivery property, optionally test it, and finally promote it to production for use.

Once live in production, request logic for your content works as follows:

  • A request to http://quick-images-lo-res.com. Since this matches the quick-images-lo-res.com property hostname set in the "Lo-res NetStorage" rule, its Origin Server is used, and its versions of the Origin Characteristics, Content Characteristics, and Client Characteristics behaviors are applied. However, the Default Rule applies to all requests. So, all of its additional behaviors are also applied—use case-based behaviors or not. For example, what you've set for the Client Characteristics behavior in the Default Rule is used because there's no instance of that use case-based behavior in the "Lo-res NetStorage" rule.

  • A request to https://quick-images-hi-res.com. The "Lo-res NetStorage" rule is checked first, but this request doesn't match its criteria. So, the request references the Default Rule, and its Origin Server is used, as well as what's been set in its instances of the Origin Characteristics, Content Characteristics, and other behaviors.