Azure Web 应用程序 - HTTP 超时
Azure Web App - HTTP time out
部署到我们的 Azure Web 应用程序后,我们对服务的任何请求都会出现 500 次超时:
500 - The request timed out.
The web server failed to respond within the specified time.
这是突然发生的,我们无法确定是什么原因造成的。似乎需要大约 230 秒才能超时。
我已在门户中启用所有诊断日志:
但老实说,我不太清楚要在日志中查找什么。我已经搜索了以下文件夹中的所有文件,但没有任何内容跳出。
我该如何解决这个问题?
获取调试消息的技巧是在您的配置中设置 stdoutLogFile="D:\home\LogFiles\stdout.log"
,而不是您拥有的 ..\logs
路径。更改后,您会在 D:\home\LogFiles
下得到一个错误文件。这是您得到的错误:
Application startup exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentNullException: SMTP server password cannot be null or empty.
Parameter name: smtpPassword
at TransitApi.Infrastructure.Modules.Logging.EmailOutput.EmailLogger..ctor(String recipient, String sender, String smtpUsername, String smtpPassword, String smtpHost, Int32 smtpPort, String environmentName, LogLevel minimumLevel)
at TransitApi.Infrastructure.Modules.Logging.EmailOutput.EmailLoggerProvider.CreateLogger(String name)
at Microsoft.Extensions.Logging.Logger.AddProvider(ILoggerProvider provider)
at Microsoft.Extensions.Logging.LoggerFactory.AddProvider(ILoggerProvider provider)
at TransitApi.Api.Startup.Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
设置邮件服务器时出现了某种问题。这会导致进程崩溃,并且表现不佳。
但我强烈建议您升级到 Core RC2,因为 RC1 已经过时了。
部署到我们的 Azure Web 应用程序后,我们对服务的任何请求都会出现 500 次超时:
500 - The request timed out.
The web server failed to respond within the specified time.
这是突然发生的,我们无法确定是什么原因造成的。似乎需要大约 230 秒才能超时。
我已在门户中启用所有诊断日志:
但老实说,我不太清楚要在日志中查找什么。我已经搜索了以下文件夹中的所有文件,但没有任何内容跳出。
我该如何解决这个问题?
获取调试消息的技巧是在您的配置中设置 stdoutLogFile="D:\home\LogFiles\stdout.log"
,而不是您拥有的 ..\logs
路径。更改后,您会在 D:\home\LogFiles
下得到一个错误文件。这是您得到的错误:
Application startup exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentNullException: SMTP server password cannot be null or empty.
Parameter name: smtpPassword
at TransitApi.Infrastructure.Modules.Logging.EmailOutput.EmailLogger..ctor(String recipient, String sender, String smtpUsername, String smtpPassword, String smtpHost, Int32 smtpPort, String environmentName, LogLevel minimumLevel)
at TransitApi.Infrastructure.Modules.Logging.EmailOutput.EmailLoggerProvider.CreateLogger(String name)
at Microsoft.Extensions.Logging.Logger.AddProvider(ILoggerProvider provider)
at Microsoft.Extensions.Logging.LoggerFactory.AddProvider(ILoggerProvider provider)
at TransitApi.Api.Startup.Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
设置邮件服务器时出现了某种问题。这会导致进程崩溃,并且表现不佳。
但我强烈建议您升级到 Core RC2,因为 RC1 已经过时了。