Sub Application_Start() Dim loFieldInfo As FieldInfo = Nothing Dim loMethodInfo As MethodInfo = Nothing Dim loObject As Object = Nothing Dim loObject2 As Object = Nothing Dim loPropertyInfo As PropertyInfo = Nothing RegisterSoapExtension(GetType(TraceExtension), 1, 0) ' Microsoft IIS/ASP.NET has a bug that after a very long period of time, it can start restarting the worker process ' several times per minute, for days, causing an enormous amount of load ' As there is no guarantee this will come back, we disable this FCN at this level ' This code will turn off monitoring from the root website directory, but monitoring of Bin, App_Themes and other folders will ' still be operational, so updated DLLs will still auto deploy loPropertyInfo = GetType(System.Web.HttpRuntime).GetProperty("FileChangesMonitor", _ BindingFlags.NonPublic Or BindingFlags.Public Or BindingFlags.Static) loObject = loPropertyInfo.GetValue(Nothing, Nothing) ' Turn off FCN on the sub directories loFieldInfo = loObject.GetType().GetField("_dirMonSubdirs", BindingFlags.Instance Or BindingFlags.NonPublic Or BindingFlags.IgnoreCase) loObject2 = loFieldInfo.GetValue(loObject) ' Send the deactivation notice loMethodInfo = loObject2.GetType().GetMethod("StopMonitoring", BindingFlags.Instance Or BindingFlags.NonPublic) loMethodInfo.Invoke(loObject2, New Object() {}) End Sub