-
Notifications
You must be signed in to change notification settings - Fork 1
Output caching
In the context of the OWIN framework Output Caching refers to a type of middleware that will save the response to a request, and if it sees an identical request in the future will return the saved response rather than executing the rest of the middleware in the OWIN pipeline.
Output caching is a very complicated type of middleware to write with many optimizations and tradeoff possibilities. The output cache also needs hints from the rest of the OWIN pipeline about what can or can't be cached, and how worthwhile it will be to cache a particular request.
Assuming that there is a limited amount of memory available and a large number of possible requests, the output cache needs to decide which responses to cache and for how long based on the size of the response, the frequency of requests for this resource and the cost saving in serving the request from cache rather than executing the rest of the OWIN pipeline to recreate this response.