Caching is a two-edged sword. It is essential to the performance of your site, but it becomes a problem when you, or the business, needs to affect a high priority change in production. If you are using the HTTP runtime’s cache, the only way you can force the cache to update is to recycle the app pool. If you manage to convince the server admin to do this for you in production, this means that your users, and users of other site collections on the app pool will be negatively impacted.
Introducing the Cache Monitor. This is a simple tool that allows site collection administrators to search for cache items (by item key) and remove them from the cache, hence forcing the items to be refreshed.
Users access the tool from Site Settings \ Site Collection Administration.
Users search for items by key and choose the items to delete from the cache.
After deploying the solution, you need to active the site collection feature BNH.SharePoint.CacheMonitor.
This solution works with the HTTP runtime’s cache only.
1. Download the solution
You can download the complete Visual Studio solution here.
2. Interesting points
The code pretty much is just straightforward ASP.NET. One thing worth mentioning is how to handle the SPMenuField click event on server-side as a postBack. I have written about that here.
3. Check out my other solutions
Check out my other custom solutions that fill certain gaps in SharePoint here.