(C#) および (ASP.NET Web API) と MS SQL 2008 R2 を使用して Web アプリケーションを開発し、Windows Server 2008 の IIS7 でホストしています。すべての API は JSON でデータを返します。
任意の Web ブラウザーから任意の API を呼び出し、ページを更新して最初の呼び出しが終了する前にもう一度呼び出すと、イベント ビューアーに警告が表示され、0 ~ 5 分後に II7 のワーカー プロセスが約 2 分間停止 (ハング) し、この 2 分間にすべてのユーザーからのすべての API 呼び出しが機能せず、イベント ビューアで次のエラーが表示されます。
イベント ビューアの警告
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 6/5/2012 3:29:10 PM
Event time (UTC): 6/5/2012 1:29:10 PM
Event ID: 63adcb812864465cab58e9f870bcbb92
Event sequence: 5
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/2/ROOT/AAA-2-129833765408950000
Trust level: Full
Application Virtual Path: /AAA
Application Path: C:\inetpub\wwwroot\AAA\
Machine name: MyMachine
Process information:
Process ID: 9860
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Exception information:
Exception type: HttpException
Exception message: The remote host closed the connection. The error code is 0x800704CD.
at System.Web.Http.WebHost.HttpControllerHandler.EndProcessRequest(IAsyncResult result)
at System.Web.Http.WebHost.HttpControllerHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
Request information:
Request URL: My API URL
Request path: API Path
User host address: My IP
User:
Is authenticated: False
Authentication Type:
Thread account name: NT AUTHORITY\NETWORK SERVICE
Thread information:
Thread ID: 8
Thread account name: NT AUTHORITY\NETWORK SERVICE
Is impersonating: False
Stack trace: at System.Web.Http.WebHost.HttpControllerHandler.EndProcessRequest(IAsyncResult result)
at System.Web.Http.WebHost.HttpControllerHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
イベントビューアのエラー
An unhandled exception occurred and the process was terminated.
Application ID: /LM/W3SVC/2/ROOT/AAA
Process ID: 9860
Exception: System.AggregateException
Message: A Task's exception(s) were not observed either by Waiting on the Task or accessing its Exception property. As a result, the unobserved exception was rethrown by the finalizer thread.
StackTrace: at System.Threading.Tasks.TaskExceptionHolder.Finalize()
InnerException: System.Web.HttpException
Message: The remote host closed the connection. The error code is 0x800704CD.
StackTrace: at System.Web.Http.WebHost.HttpControllerHandler.EndProcessRequest(IAsyncResult result)
at System.Web.Http.WebHost.HttpControllerHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)