ltm rule command CACHE uriΒΆ

iRule(1)						BIG-IP TMSH Manual						  iRule(1)

CACHE::uri
       Overrides the URI value used by the cache to store the cached content.

SYNOPSIS
       CACHE::uri URI_STRING

DESCRIPTION
       By default, cached content is stored with a unique key that consists of the Host header, URI, Accept-Encoding and User-
       Agent. If multiple variations of the same content must be cached under specific conditions (different client), you can use
       this command to modify URI and 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.

       If any of the key elements is rewritten at the HTTP level (HTTP_REQUEST), the key uses those values, not the original
       values.

       CACHE::uri 

	    * 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.)

RETURN VALUE
VALID DURING
       HTTP_REQUEST, HTTP_REQUEST_DATA

EXAMPLES
	To cache documents using unique, per-session virtual URI keys without actually
	changing the URI on the wire (prevents sharing of cached content between
	sessions).

	when HTTP_REQUEST {
	  set my_session_string 
	  CACHE::uri [HTTP::uri]$my_session_string
	}

HINTS
SEE ALSO
CHANGE LOG
       @BIGIP-9.2.0 --First introduced the command.

BIG-IP							    2022-04-12							  iRule(1)