【发布时间】:2014-11-27 00:28:02
【问题描述】:
错误
源文件: c:\Projects\WaterfrontSeattle.org\src\Orchard\Logging\OrchardLog4netLogger.cs
行: 63
来源错误:
Line 61: // Load the log4net thread with additional properties if they are available
Line 62: protected internal void AddExtendedThreadInfo() {
Line 63: if (_shellSettings.Value != null) {
Line 64: ThreadContext.Properties["Tenant"] = _shellSettings.Value.Name;
Line 65: }
研究
从 DuckDuckGoing 中,我们了解到,当我们尝试访问惰性值时会发生这种类型的错误。 Codeplex 上的一些 Orchard 论坛帖子表明,这意味着该模块已过时,需要更新才能工作。一些 Orchard Gallery 帖子建议清除 Orchard 缓存作为修复。这些对我们来说都不是真的。
我们的解决方法
- 删除 App_Data。
- 从所有位置移除模块。
- 重新创建网站。
- 恢复数据库。
- 从 Visual Studio 的包管理器安装模块。
验尸
似乎解决方法中最重要的部分是删除 App_Data。导致错误的 App_Data 内部是什么?我们之前曾尝试删除 cache.dat 文件但没有成功。 App_Data 中还有什么我们可以删除的?
另见
【问题讨论】:
标签: c# orchardcms-1.8