CACHE::uri

Description

Overrides the URI value used by the cache to store the cached content.
Cached content by default is stored with a unique key referring to both the URI of the resource to be cached and the User-Agent for which it was formatted. If multiple variations of the same content must be cached under specific conditions (different client), you can use this command to create a unique key, thus creating cached content specific to that condition. This can be used to prevent one user or group’s cached data from being served to different users/groups.

Syntax

CACHE::uri <string>

CACHE::uri <string>

  • Overrides the default URI key value used by the cache to store the cached content, according to the specified string. (Does NOT change the URI on the wire as HTTP::uri does.)

Examples

To force documents to be cached under unique, per-session virtual URI key without actually changing the URI on the wire (Prevents sharing of cached content between sessions.)
when HTTP_REQUEST {
  set my_session_string <unique session value>
  CACHE::uri [HTTP::uri]$my_session_string
}