How to refresh ASP.NET Mono page without restarting web server?

When I make changes to the file, ASP.NET Mono doesn't see my changes, I have to do this:

sudo /etc/init.d/apache2 restart

      

I remember when Mono ASP.NET executes ASP.NET it caches the compilation somewhere. Until then, when the refreshed page doesn't show up, I just delete this cached compiled code. I just forgot the exact path

How do I make Mono ASP.NET detect the changes I made to the program without restarting the web server?

+2


a source to share


2 answers


It looks like FileSystemWatcher doesn't see changes from Windows side.

After upgrading from Windows side, go to Linux side and do the following:



tap Web.Config

or any file in the directory. This should notify ASP.Net that your new code has loaded.

+3


a source


This command is to restart the application and recompile if necessary. (without restarting the web server).

Can you test it if you are doing the job?



HttpRuntime.UnloadAppDomain();

      

Another way is to create an app_offline.htm file for root, download your changes, and then delete it.

0


a source







All Articles