[英]After reboot: NullReferenceException at System.Web.PipelineStepManager.ResumeSteps
(Almost) every morning, after booting my laptop, starting IIS, and browsing to a specific asp.net mvc web application on my PC, I get this exception: (几乎)每天早上,在启动我的笔记本电脑,启动IIS,并在我的PC上浏览到特定的asp.net mvc Web应用程序后,我得到以下异常:
[NullReferenceException: Object reference not set to an instance of an object.]
System.Web.PipelineStepManager.ResumeSteps(Exception error) +1781
System.Web.HttpApplication.BeginProcessRequestNotification(HttpContext context, AsyncCallback cb) +130
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +481
After iisreset, this is solved. 在iisreset之后,这个问题就解决了。 It only happens at my own laptop, not on a stage or live server where the same asp.net mvc application is running 它只发生在我自己的笔记本电脑上,而不是在运行相同的asp.net mvc应用程序的舞台或现场服务器上
I already checked: 我已经检查过:
I'm using an app pool in Integrated mode on .net CLR version 4.0.30319 Target framework is .Net 4.5.2 我在.net CLR版本4.0.30319上使用集成模式的应用程序池。目标框架是.Net 4.5.2
my global.asax looks like this: 我的global.asax看起来像这样:
public class MvcApplication : HttpApplication {
protected void Application_Start() {
AreaRegistration.RegisterAllAreas();
GlobalConfiguration.Configure(WebApiConfig.Register);
FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
RouteConfig.RegisterRoutes(RouteTable.Routes);
BundleConfig.RegisterBundles(BundleTable.Bundles);
ModelBinders.Binders.Add(typeof(DateTime), new DateTimeModelBinder());
ModelBinders.Binders.Add(typeof(DateTime?), new NullableDateTimeModelBinder());
ClientDataTypeModelValidatorProvider.ResourceClassKey = "ValidationMessages";
DefaultModelBinder.ResourceClassKey = "ValidationMessages";
}
protected void Application_BeginRequest(object sender, EventArgs e) {
CultureInfo ci = new CultureInfo(LanguageHelpers.GetUserCultureName());
System.Threading.Thread.CurrentThread.CurrentUICulture = ci;
System.Threading.Thread.CurrentThread.CurrentCulture = ci;
}
public void Application_Error(object sender, EventArgs e) {
if (!Request.IsLocal) {
....
}
}
}
After taking look at error on internet, i think you have two option. 在看了互联网上的错误后,我认为你有两个选择。
See if this works or not. 看看这是否有效。
Also, do you getting this error for any other project or maybe create new one and check this out? 此外,您是否为任何其他项目收到此错误,或者创建新项目并检查出来? If yes then probably reintalling IIS will fix this. 如果是,那么可能重新安装IIS将解决这个问题。
Server error '/' Application. 服务器错误'/'应用程序。 - HttpException - HttpException
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.