locked
Updating cache on IIS recycle RRS feed

  • Question

  • User13887313 posted

    Hello friends, I am writting from South America, very pleased to become a part of your great forum that helped me so many times.

     

    This time I have a quite difficult question, or at least some gurus I talked about where not able to manage a solution.

     

    The scenario is quite simple, so it is weird to me that I got to the point of having not a clue at all of what to do.

     

    I have an ASP.NET that has quite a big cache. The cache is big but quite simple. I handle it  with some classes which have some static attributes and the static methods to load and retrieve the data that I need.

     

    The problem is that I want to start recycling the IIS during the night, for performance reasons and sometimes (every 15/30 days) the server is restarted to install some security patches. I load the cache in the global.asax Application_Start method , and here we have the problem. This method is only called on the first request to the web page. The cache takes about 10 minutes to load, and besides, launches some threads that do some very important things. So it is really really complicated to wait for the first request to reload the cache. I want it to be reloaded inmediately after the recycling is done (or the server is restarted).

    The only thing I can think of, is a windows task that calls a web service in my web page so it starts loading the cache.

     

    Something better??

     

    Thanks thanks in advance... I really appreciate your help.

     

    Zim

    Monday, July 27, 2009 11:30 AM

Answers

  • User511787461 posted

    Look at the "Auto start web application" topic at this link - available with IIS 7.5 on WS08 R2

    • Marked as answer by Anonymous Tuesday, September 28, 2021 12:00 AM
    Monday, July 27, 2009 11:39 AM

All replies

  • User511787461 posted

    Look at the "Auto start web application" topic at this link - available with IIS 7.5 on WS08 R2

    • Marked as answer by Anonymous Tuesday, September 28, 2021 12:00 AM
    Monday, July 27, 2009 11:39 AM
  • User13887313 posted

     mmmm... that looks like exactly what I need...

     

    thanks a lot!!!

     

    I'll try it and tell you how it works

    Tuesday, July 28, 2009 6:24 PM