How to enable CDN optimizations

Media Services logo v3


Warning

Azure Media Services will be retired June 30th, 2024. For more information, see the AMS Retirement Guide.

To get the best performance from streaming endpoint CDN, you may want to change the way it behaves based on certain conditions. This article covers how to use the Azure portal and the CDN Rules Engine to adjust the behavior of a CDN profile.

Prerequisites

  • Read the article Scale Streaming with a CDN to understand how CDN caching works.
  • A Media Services account with at least one streaming endpoint.

Create a streaming endpoint

If you don't want to use the default streaming endpoint, you can create a new streaming endpoint:

  1. Sign in to the Azure portal.
  2. Navigate to the Media Services account you want to use.
  3. Select Streaming endpoints.
  4. Select + Add a streaming endpoint. The Create a streaming endpoint screen will appear.
  5. Enter a name into the Streaming endpoint name field.
  6. Select either the Standard or Premium radio button for the streaming endpoint type.
  7. Select either the Yes or No radio button for starting the streaming endpoint after creation.
  8. Under the Content Delivery Network section, select Premium Verizon from the CDN pricing tier dropdown menu.
  9. Select the Select existing radio button to select the CDN profile.
  10. For CDN Profile name, the AzureMediaStreamingPlatformCdnProfile-PremiumVerizon profile should already be selected.
  11. Add tags if needed.
  12. Select Create. Once the streaming endpoint has been created, it will show up on the list of streaming endpoints.

Add conditional rules for a Premium Verizon CDN

From the streaming endpoint screen:

  1. Select the new streaming endpoint from the list.
  2. In the CDN card, select the AzureMediaStreamingPlatformCdnProfile-PremiumVerizon profile. The Profile screen will appear.
  3. Select Manage. A CDN origin management page will open in a new tab or window in your browser.
  4. From the menu, select HTTP Large > Rules Engine V4.0.
  5. Select + New to create a new draft.
  6. Enter a name into the Draft Name Required field.
  7. Select Continue. The Rule Builder screen will appear.
  8. Select +Rule. Rule 1 interface will appear.
  9. Give the rule a description in the Rule Description field (optional).
  10. Select + > Match.
  11. Create the conditions of the rule using the drop down menus. For example:
    • If General + Always
      • Feature
        • Specialty + Streaming optimization
  12. Select yes to enable the rule.
  13. Select Save.

Get help and support

You can contact Media Services with questions or follow our updates by one of the following methods: