Manually Override Cache-Control Directives Using ARR
Applies To: Windows 7, Windows Server 2008, Windows Server 2008 R2, Windows Vista
This topic describes how to write a cache control rule to manage the cache control directives that control caching behavior such as the ability to cache and cache duration. This is particularly useful when the cache control directives are missing in the response header or when you want to override the cache control directives in a response. Note that Application Request Routing (ARR) will override any directives in a response header. For example, if the response header says, “Do not cache,” but the cache control rule is set to cache, ARR will cache the content. You should be familiar with the disk-based cache feature in ARR before you continue.
Configure Cache Control Rules
ARR allows for multiple cache control rules, including rules to only cache content based on URL patterns or host names, or to not cache certain content. The cache control rules are processed in the list from top to bottom.
To configure cache control rules
Open IIS Manager.
In the Connections pane, expand the server node.
In the Server pane, double-click Application Request Routing Cache.
On the Application Request Routing Cache page, in the Actions pane, click Cache Control Rules….
On the Cache Control Rules page, in the Actions pane, click Add….
In the Add Cache Control Rule dialog box, follow these steps:
In the Apply rule list, select when you want to apply the cache control rule: When no cache control directive exists or Always.
Select Do not cache or Cache.
If you selected Cache, enter the duration in the Cache duration (minutes) box.
In the Host name box, optionally enter the name of your host site.
In the URL box, optionally enter the URL.
Click OK.
See Also
Concepts
Disk Caching Tasks for IT Pros
ARR Tasks for IT Pros
ARR Common Tasks