How to disable the process termination by IIS when debugging

When you are writing great lines of code for your SharePoint solution, you’ll probably be testing and debugging that code as well. You deploy your solution, attach Visual Studio to the worker process and when the debugger hits the breakpoint, you examine what happens and read the values of your variables at that moment. And before you know it, you get the message that IIS has terminates the process that was being debugged.

IISDebugTimeOut

What happens here? The Windows Process Activation Service (WAS) pings an application pool’s worker process at set intervals for monitoring. If a worker process is non-responsive, WAS can shut it down. This WAS pinging is enabled by default and the interval is set to 90 seconds.

To avoid this you can either disable the Ping Enabled setting of the application pool of your web application or increase the Ping Maximum Response Time. From the Administrative Tools menu, start the Internet Information Services (IIS) Manager and expand your server. Select the Application Pools node. In the Application Pools list select your application of your web application and click on the Advanced Settings link.

IISAppPoolAdvancedSettings

Now set Ping Enabled to false (or increase Ping Maximum Response Time to 900) and save your settings by clicking the OK button. You will now be able to answer the phone again while debugging and analyzing your code.

Share