Azure Content Delivery Network (CDN)

Azure CDN is a global content delivery solution that enhances the performance and availability of your web applications by caching content at strategically placed locations worldwide. This reduces latency for users accessing content from distant locations.

Purpose of Azure CDN

Consider a scenario where a large amount of video content is hosted in Australia, but the primary audience is in the United States and India. Without a CDN, users in these locations would experience significant latency due to the physical distance to the content’s origin. Azure CDN helps mitigate this issue by caching the content closer to users, thereby improving load times and user experience.


CDN Products

Azure offers several CDN products, including partnerships with third-party providers:

  1. Azure CDN Standard from Microsoft (Preview)
  2. Azure CDN Standard from Akamai
  3. Azure CDN Standard from Verizon
  4. Azure CDN Premium from Verizon

Features of Azure CDN

Key Features

  • Dynamic Site Acceleration: Improves the delivery of dynamic content by optimizing routes and using techniques like TCP optimization, reducing latency.
  • HTTPS Support: Ensures secure delivery of web content over HTTPS.
  • Query String Caching: Allows caching of content based on query strings for dynamic URLs.
  • Geo-Filtering: Enables filtering of content based on geographical regions to control access.
  • Azure Diagnostics Logs: Provides logging capabilities to track and analyze CDN usage and performance.

CDN Configuration

Setting up Azure CDN involves a few key steps:

  1. Create a CDN Profile:
    • This profile is a collection of CDN endpoints. By default, a profile can contain up to 10 endpoints.
    • When creating a CDN profile, you must specify the product type (e.g., Premium from Verizon, Standard from Microsoft).
  2. Create a CDN Endpoint:
    • Define the endpoint name and specify the origin type (e.g., Azure Storage, web app, or custom origin).
    • The Origin Path must be defined to specify where the content is located, along with the protocol (HTTP/HTTPS).
    • After creation, you receive an endpoint URL (e.g., example.net).

Caching Mechanisms

Azure CDN provides multiple ways to control how files are cached:

1. Caching Rules

  • Global Caching Rules: Set rules that apply across all endpoints in the CDN profile.
  • Custom Caching Rules: Define specific caching behavior for individual endpoints or content types.

2. Purged Cached Assets

  • Allows you to remove specific files from the cache to ensure that users receive the latest version of content.

3. Pre-load Assets

  • Pre-load assets onto the Azure CDN endpoint to ensure availability before they are accessed by users, improving performance during initial requests.