Caching data from IIS?

I am being asked to investigate an intermittent issue on the WebServer that launches my command application.

Essentially, we have a web service that searches between codes. If you have a type A code, you can use it to find the corresponding type B code. Periodically, when memory is running low when this web service is called, a null reference exception is thrown. Basically, this service loads the search file into the cache with a file dependency, so if the file is running, the cache is reloaded with a new file. The priority for the cache object is set by default. My guess is that somewhere in the code it is not checked that the cache object still exists, and when the memory on the server goes low, that object is flushed, throwing an error. I would like to be able to recreate the error and test before I start digging into this code.

Is there a way in IIS Manager (or from the command line) to force a running web application to flush the cache? I would think that this should recreate the condition and therefore recreate the error. Not to mention, a part error should lead to the correct section of code.

Thank,

Steve Browillard

+1


source to share


2 answers


I found a utility that can be added to ASP.NET applications that will allow you to dynamically manage the cache as a whole or individual cache objects. Thanks to .NET Rocks! and dnrtv .

Here's a link to the tool I used. This allowed me to only clear the specific objects in question on the fly and prove the error.



Thanks everyone for your help. ASP Cache Manager .

Steve

0


source


My gut reaction would be to set the CacheDuration to zero and then revert to whatever you want permanently. I haven't tried this, but I think it is a cache dump and then will start building it again ...



0


source







All Articles