我尝试使用注册表,并将其设置为1. Web应用程序将再次启动...我也尝试了2,Web启动但文件夹删除问题仍然存在。 2并没有禁用FCN所以我猜它是预期的。
然后我尝试在web.config中使用.NET 4.5新的fcnMode值:
这与将注册表项设置为1具有完全相同的效果。
在这里你可以看到我遇到的问题。
Server Error in '/' Application.
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[NullReferenceException: Object reference not set to an instance of an object.]
System.Object.GetType() +0
<Secret.NameSpace>.OieApplication.Application_Start(Object sender, EventArgs e) +289
[HttpException (0x80004005): Object reference not set to an instance of an object.]
System.Web.HttpApplicationFactory.EnsureAppStartCalledForIntegratedMode(HttpContext context, HttpApplication app) +12600317
System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +175
System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +304
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +404
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +475
[HttpException (0x80004005): Object reference not set to an instance of an object.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +12617364
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +159
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +12456981
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34212
答案 0 :(得分:0)
对不起,如果我浪费了某些人的时间,但突然之间它的工作正常。我意识到我没有在调试模式下运行,这就是为什么我没有看到更好的堆栈跟踪。
最合乎逻辑的假设一定是人(好吧,我)因素。可能会把双重httpRuntimes或其他东西。
所以 - 再也没有错误了。但是没有解决原始问题,如下所述:ImageResizer restarts application pool