Skip to main content

Http keep alive internal

WIP. This is an internal draft. When Max Number of Requests per Connection is supported, merge the relevant info back from this topic into the published topic.

Overview

Use the HTTP Keep Alive rule to manage persistent client-to-CDN connections for faster content delivery, reduced latency, and improved performance.

Connection pooling and connection reuse is enabled by default by Qwilt CDN. The HTTP Keep Alive rule lets you control how long idle connections are kept open before being closed, and the maximum number of requests that can be handled by a single connection.

When max values are reached, a response header of "Connection=close" is sent.
:::(Error) (is the Connection=close header transparent to the user? Can I remove this info?)
Likewise, is it relevant to mention connection pooling and reuse?
:::

Configure the Rule

To configure an HTTP Keep Alive rule:
1. Navigate to the Select Rule dialog.
2. In the Select Rule dialog, choose HTTP Keep Alive.
3. Set one or both parameters:
* Maximum Idle Timeout: Specifies the number of seconds that an idle connection remains open, rather than being closed immediately when a request is fulfilled. The default is 60 seconds. The maximum supported for client-to-CDN connections is 300 seconds.

* **Max Number of Requests Per Connection**: Specifies the maximum number of requests that can be handled per connection. The default is 1000 requests. The maximum supported for client-to-CDN connections is 1000 requests.
  1. Choose Add Rule.

:::(Error) (Chris - how do you want me to handle this? Are we hiding the feature? If not, should we include this note about the impact on the edge to mid-tier connections? Should we warn them not to use the Max Requests field? Or warn them not to set a low values?)
Note: If you define a longer timeout/larger number of requests than the maximum allowed, the client-to-CDN connections will not persist for more than 300 seconds/1K requests, but the CDN to CDN or CDN to Origin connections will support the higher limit.

Follow up on Arnon reply to 8.5 Slack ask-delivery query about hiding this rule from the UI until it allows for the customer to set the client to edge persistence settings without affecting the edge to mid-tier settings. We don't want them to be able to impact our edge to mid-tier conections. When this is resolved, update this doc to make it clear that the configuration is relevant to client-edge connections only. Arnon also says that we can come up with a minimum idle time value that can be enforced, as edge-mid connections don't become idle for too long.
:::

SVTA Component: QW.ClientConnectionControl

In the configuration JSON, the SVTA metadata type for this feature is QW.ClientConnectionControl. It is added to the configuration JSON when you save the configuration version.
This is a private feature developed by Qwilt. In the JSON format, private features are nested within the MI.PrivateFeaturesList object, in the "generic-metadata-value" "features" field.

{
    "generic-metadata-type": "MI.PrivateFeatureList",
    "generic-metadata-value": {
        "features": [
            {
                "feature-type": "QW.ClientConnectionControl",
                "feature-oid": "Qwilt",
                "feature-value": {
                    "connection-keep-alive-time-ms": 60000,
                    "max-requests-per-connection": 1000
                }
            },

Note that in the SVTA object, the maximum idle timeout value is expressed in milliseconds.