If a client requests resources that are not cached on Dynamic Content Delivery Network (DCDN) points of presence (POPs), the request is redirected to the origin server to retrieve the resources. If you submit a prefetch task, the POPs retrieve resources from the origin server. This process is called origin fetch. You can configure origin fetch based on your business requirements.
Origin fetch is suitable in various scenarios, as described in the following table.
Feature | Description | Scenario |
Configure an origin host | Specify a server domain name for origin fetch | If the IP address of your origin server is associated with multiple domain names or sites, you can configure the HOST header in HTTP requests to specify the site to which requests are redirected. DCDN redirects requests to the site that is specified by the HOST header. |
Configure the static origin protocol policy | Set the origin protocol policy | If a client requests resources that are not cached on POPs, DCDN redirects the request to the origin server over the protocol that is specified in the origin protocol policy. You can set the origin protocol policy to Match Client, HTTP, or HTTPS. |
Configure private bucket origin | Retrieve content from private Object Storage Service (OSS) buckets | If your origin server is a private OSS bucket, you need to grant DCDN access permissions on the private OSS bucket before DCDN can access the bucket. Permission control can prevent hotlinking. |
Configure origin SNI | Specify a site for origin fetch | If POPs access your origin server over HTTPS and the IP address of the origin server is associated with multiple domain names, you need to configure Server Name Indication (SNI) to specify the domain name that POPs can access. |
Configure a common name whitelist | Validate client requests and reject requests that are not in the whitelist to access the origin server | When POPs connect to origin servers over HTTPS, the system compares common names in the certificates that are returned by the origin servers with the SNI values that are included in client requests. If an SNI value that is included in the client request does not match the common name in the certificate that is returned by the origin server, the client request is rejected. |
Configure range origin fetch | Return partial content within the specified range from the origin server | You can enable range origin fetch to accelerate the delivery of large files. This reduces the usage of back-to-origin data transfer and shortens the resource response time. |
Configure a timeout period for back-to-origin requests | Specify the maximum timeout period for back-to-origin requests | You can specify a timeout period for back-to-origin requests. The timeout period is the amount of time that a POP waits for a response after a request is redirected to the origin server. The default timeout period is 30 seconds. If the POP does not receive a response within the specified timeout period, the connection between the POP and origin server closes. |
Configure a custom origin HTTP header | Add, rewrite, or delete an HTTP header from back-to-origin requests | You can add HTTP headers to or delete HTTP headers from back-to-origin HTTP requests. |