Skip to content
An attempt at output caching based on the way sites actually work.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

MVC Output Cache

MVC Output Cache is an attempt to implement output caching for MVC that fixes some of the limitations of the OutputCache that comes with the framework. The idea is to make easy things easy, and hard things possible, to steal a phrase. Some scenarios:

  • Cache only for anonymous users
  • Simply not cache under defined circumstances
  • Invalidate the cache for the current user
  • Vary by ajax (very helpful if you do progressive enhancement)
  • Use a different cache duration for anonymous and authenticated users

It's made to work in conventional cases out of the box, but the core methods are designed to be overridden in inherited classes. For example, you might override the IsAnonymous method based on your own auth system, or have your own ideas about what "invalidate" means.

Something went wrong with that request. Please try again.