Consider the following scenario:
In this scenario, the following problems may occur:
Exception Details: System.InvalidOperationException: Post cache substitution is not compatible with modules in the IIS integrated pipeline that modify the response buffers. Either a native module in the pipeline has modified an HTTP_DATA_CHUNK structure associated with a managed post cache substitution callback, or a managed filter has modified the response.
Response filtering and post-cache substitution are not compatible.
To avoid the problem, choose one of the following options:
Post-cache substitution is implemented using a list of substitution blocks (.NET delegates) used to reconstruct individual pieces of the response. ASP.NET internally maintains a list of HTTP_DATA_CHUNK structures associated with a managed post-cache substitution callback. When a response filter is used, a raw response is rendered into a single buffer and the list of substitution blocks is lost. Therefore, the substitution blocks cannot be rendered.
For more information on post-cache substitution, please see:
Caching Portions of an ASP.NET Page
Article ID: 2014472 - Last Review: 01/19/2010 18:49:00 - Revision: 2.0