Dynamic Caching Configuration

Dynamic Caching creates the optimal user experience for your new site visitors, eliminating the delay these visitors usually experience when loading a new website for the first time. This feature enables Instart Logic’s service to predictively preload dynamically-generated web pages and serve them from cache to first-time visitors. By avoiding the round trip back to the customer’s origin, Dynamic Caching improves performance by 30 to 50% for first-time visits to a customer’s website.

Commonly, for a first-time visitor to a website, the HTML response is essentially the same across all users, except that each user requires a unique identifier, generally in the form of a cookie. Therefore, a first-time visitor has to make a round trip back to the origin is order to fetch this unique identifier, increasing page load times for first-time visitors to the site. With our Dynamic Caching technology, we can predictively request a series of responses containing unique identifiers and store them in a short-term queue on our service. As first-time visitors come to a site, one of these responses in the queue is issued without the need to go to the origin server. Meanwhile, a new identifier is requested from the origin to replace the one depleted and is added to the queue in advance of future first-time users.

For more information about the Dynamic Caching feature, read our knowledge base document What Is Dynamic Caching?

Here's a typical Dynamic Caching example:

"otc": {
  "op": {
    "enable": true
  },
  "cache_ttl": "1201s",
  "num_prefetch_objects_per_resource": 3
}

The following fields and blocks can be used to control Dynamic Caching:

Field or blockDescription
opA content operation block where the feature can be enabled, and constraints configured for not applying it even though enabled – for example, min/max file sizes for which this operation can be applied
exempt_cookie_keysAn optional list of cookie keys which are to be exempted (whitelisted) for Dynamic Caching. This can accept a regex; for example, ".*" will exempt all cookies.
cache_ttl

The length of time that a prefetched object will be kept in the feature cache. It consists of an integer value suffixed by either s (seconds), m (minutes), h (hours), or d (days).

The default is 283s (approx. 5 1/2 m).

Note: A prime number helps reduce the potential for a race condition between object expiry and requests which come periodically (for example, the Google bot).

num_prefetch_objects_per_resource

The number of prefetched objects allowed for each distinct resource.

The default is 1.

auto_prefetch_duration

Duration that auto prefetch continues in the absence of real traffic. It consists of an integer value suffixed by either s (seconds), m (minutes), or h (hours).

The default is 1h.

disable_auto_prefetch

Set to true, this disables auto prefetch.

The default is false.

num_min_hits_otc_trigger

Enables long tail handling and sets a minimum number of hits to trigger Dynamic Caching. The default is 0.

Note

Dynamic Caching does not work when the origin server sends content based on client IP address. In general, Dynamic Caching should not be enabled if client IP address tracking is desired.