The set-cache-control function allows you to specify the HTTP caching policy for the response being sent back to the client.
The following table describes parameters for the set-cache-control function.
Table 7–62 set-cache-control Parameters
Parameter |
Description |
---|---|
HTTP cache control directives. Separate multiple directives by commas. |
|
bucket |
(Optional) Common to all obj.conf functions. Adds a bucket to monitor performance. For more information, see The bucket Parameter. |
The following table describes some of the useful cache control directives defined by the HTTP/1.1 protocol.
Table 7–63 Cache Control Directives
Directive |
Description |
---|---|
public |
The response may be cached by any cache. |
private |
The response must not be cached by a shared cache (for example, a proxy server). |
no-cache |
Clients must ask the server for updated content on each access. |
max-age=n |
The response should not be cached for more than n seconds. |
ObjectType fn="set-cache-control" control="private,max-age=60"