我将sitecore从7.1升级到7.2并更改了所有的configurtion文件,如所述并收到错误找不到配置节点:settings / setting [@ name ='mediaFolder'] / @ value“。但我的webconfig有以下值< / p>
<setting name="MediaFolder" value="$(mediaFolder)" />
<sc.variable name="mediaFolder" value="/upload" />
<media>
<folder ref="settings/setting[@name='mediaFolder']/@value">
</folder>
<filter>*</filter>
</media>
The stacktrace
找不到配置节点: 设置/设定[@名称= 'mediaFolder'] / @值
描述:执行期间发生了未处理的异常 当前的网络请求。请查看堆栈跟踪了解更多信息 有关错误的信息以及它在代码中的起源。
异常详细信息:System.InvalidOperationException:找不到 配置节点:设置/设置[@ name ='mediaFolder'] / @ value
来源错误:
执行期间生成了未处理的异常 当前的网络请求。有关的来源和位置的信息 可以使用下面的异常堆栈跟踪来识别异常。
堆栈追踪:
[InvalidOperationException:找不到配置节点: 设置/设定[@名称= 'mediaFolder'] / @值]
Sitecore.Diagnostics.Assert.IsTrue(布尔条件,字符串消息) +70 Sitecore.Diagnostics.Assert.IsTrue(布尔条件,字符串格式,对象[] args)+82
Sitecore.Configuration.Factory.GetConfigNode(String xpath,Boolean 断言)+281 Sitecore.Configuration.Factory.CreateObject(String configPath,String []参数,布尔断言)+158
Sitecore.Configuration.Factory.CreateFromReference(XmlNode configNode, String []参数,布尔断言)+203
Sitecore.Configuration.Factory.CreateObject(XmlNode configNode, String []参数,布尔断言,IFactoryHelper助手)+161
Sitecore.Configuration.Factory.CreateObject(XmlNode configNode, String []参数,布尔断言)+64
Sitecore.Configuration.Factory.CreateObject(String configPath, String []参数,布尔断言)+461
Sitecore.Configuration.Factory.CreateObject(String configPath,Boolean 断言)+61 Sitecore.Configuration.Factory.GetString(String configPath,布尔断言)+63
Sitecore.IO.FileWatcher..ctor(String configReference)+222
Sitecore.Resources.Media.UploadWatcher..ctor()+50[TargetInvocationException:目标抛出了异常 调用。] System.RuntimeTypeHandle.CreateInstance(RuntimeType type,Boolean publicOnly,Boolean noCheck,Boolean&amp; canBeCached, RuntimeMethodHandleInternal&安培; ctor,布尔&amp; bNeedSecurityCheck)+0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly,Boolean skipCheckThis,Boolean fillCache,StackCrawlMark&amp; stackMark)+113
System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis,Boolean fillCache,StackCrawlMark&amp; stackMark) +232 System.Activator.CreateInstance(Type type,Boolean nonPublic)+83 System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr,Binder binder,Object [] args,CultureInfo culture,Object [] activationAttributes,StackCrawlMark&amp; stackMark)+1122
System.Activator.CreateInstance(Type type,BindingFlags bindingAttr, Binder binder,Object [] args,CultureInfo culture,Object [] activationAttributes)+128 System.Activator.CreateInstance(Type type,BindingFlags bindingAttr,Binder binder,Object [] args, 文化信息文化)+18
System.Web.HttpRuntime.CreateNonPublicInstance(Type type,Object [] args)+60
System.Web.HttpApplication.BuildIntegratedModuleCollection(List`1 moduleList)+189
System.Web.HttpApplication.GetModuleCollection(IntPtr appContext)+950 System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr的 appContext,HttpContext上下文,MethodInfo []处理程序)+82
System.Web.HttpApplication.InitSpecial(HttpApplicationState状态, MethodInfo [] handlers,IntPtr appContext,HttpContext context)+172
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr的 appContext,HttpContext context)+336
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr的 appContext)+296[HttpException(0x80004005):目标抛出了异常 一个调用。] System.Web.HttpRuntime.FirstRequestInit(HttpContext context)+9948312 System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +101 System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest) wr,HttpContext context)+254
答案 0 :(得分:1)
问题是Sitecore.ContentSearch.config丢失了&#39;&lt;&#39;评论部分。
答案 1 :(得分:0)
该设置区分大小写。更改您的参考:
<folder ref="settings/setting[@name='MediaFolder']/@value">
</folder>