Which one of the following is better for setting up the caching options of the static content (i.e. js,css,Images) for asp.net mvc2 applications:
** - Web.config:**
<?xml version="1.0"?>
<configuration>
<system.webServer>
<!--Caching-->
<staticContent>
<clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="365.00:00:00"/>
</staticContent>
</system.webServer>
</configuration>
Or
<?xml version="1.0"?>
<configuration>
<system.webServer>
<!--Caching-->
<staticContent>
<clientCache cacheControlMode="UseExpires" httpExpires="Tue, 31 Dec 2030 12:00:00 GMT"/>
</staticContent>
</system.webServer>
</configuration>
In short I want to know which of the options : UseMaxAge , UseExpires are better. What are the impacts on it if I remove the ETags in the request and response headers by using the HttpModules.
Can anyone help me to know more details about the above issue?
Thanks & Regards, Santosh Kumar Patro