我正在使用Server.Transfer.一切正常,但异常日志显示以下异常.
System.Threading.ThreadAbortException: Thread was being aborted.
at System.Threading.Thread.AbortInternal()
at System.Threading.Thread.Abort(Object stateInfo)
at System.Web.HttpResponse.End()
at System.Web.HttpServerUtility.Transfer(String path, Boolean preserveForm)
at System.Web.HttpServerUtility.Transfer(String path)
Run Code Online (Sandbox Code Playgroud)
任何想法避免上述异常.
在过去的几天里,我们看到w3wp.exe工作进程间歇性崩溃,为我们公司网站的主应用程序池提供服务.有时崩溃是孤立的,IIS可以成功重启工作进程.但如果在5分钟内发生超过5次崩溃,IIS Rapid Fail Protection将启动并停止应用程序池.以下是崩溃前应用程序事件日志中的示例条目:
An unhandled exception occurred and the process was terminated.
Application ID: /LM/W3SVC/2/ROOT
Process ID: 3640
Exception: System.Threading.ThreadAbortException
Message: Thread was being aborted.
StackTrace: at System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context)
at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)
at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr rootedObjectsPointer, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)
Run Code Online (Sandbox Code Playgroud)
由于ThreadAbortException导致崩溃后立即记录了一个更严重的事件:
Faulting application name: w3wp.exe, version: 8.0.9200.16384, time stamp: 0x5010885f
Faulting module name: KERNELBASE.dll, version: 6.2.9200.17366, time stamp: 0x554d16f6
Exception code: 0xe0434352
Fault offset: 0x00010192
Faulting process id: 0xe38
Faulting …Run Code Online (Sandbox Code Playgroud) 我已经在本地IIS中配置了我的asp .net网站,如果我在app_Code文件中进行了任何更改,那么网站就会被编译,并且某些时候"线程正在被中止"错误被引发.我找不到原因或重现问题..给一些建议..