When Dynamic Route for CDN (DCDN) cannot return the requested resources from the cache of the node nearest to the requester, it retrieves these resources from the origin by using the configured origin protocol policy. Then, it returns the retrieved resources to the requester and caches them to the node. This topic describes how to configure the origin protocol policy.

Background information

If you set the origin protocol policy to Match Client, DCDN communicates with the origin by using HTTP or HTTPS, depending on the protocol of the client request. For example, if the client sends an HTTPS request to access resources that are not cached on a DCDN node, the node uses the HTTPS protocol to request resources from the origin. Similarly, if the client uses the HTTP protocol to request resources from the origin, the DCDN node also uses the HTTP protocol to request resources from the origin.

Note The origin must support port 80 and port 443. Otherwise, the back-to-origin process may fail.

Procedure

  1. Log on to the DCDN console.
  2. In the left-side navigation pane, click Domain Names.
  3. On the Domain Names page, find the domain name that you want to manage, and click Configure in the Actions column.
  4. In the left-side navigation pane on the details page of the specified domain, click Origin Fetch.
  5. On the Origin Fetch tab, find Static Origin Protocol Policy.
  6. Turn on Static Origin Protocol Policy.
  7. In the Static Origin Protocol Policy dialog box, set Redirect Type to Match Client, HTTP, or HTTPS.
    Static origin protocol policy

    To enable DCDN to communicate with the origin by using HTTP or HTTPS, depending on the protocol of the client request, you must set Redirect Type to Match Client.

    Note After the static origin protocol policy is enabled, the port that you specify to forward requests to the origin in the DCDN console becomes invalid.
    Parameter Description
    Match Client DCDN communicates with the origin by using HTTP or HTTPS, depending on the protocol of the client request.
    HTTP If the client uses the HTTP or HTTPS protocol to request resources from the origin, DCDN uses only HTTP to access the origin.
    HTTPS If the client uses the HTTP or HTTPS protocol to request resources from the origin, DCDN uses only HTTPS to access the origin.
  8. Click OK. The configuration is complete.