【问题标题】:High CPU usage when deploying content types via a SharePoint feature通过 SharePoint 功能部署内容类型时 CPU 使用率高
【发布时间】:2009-02-13 13:48:24
【问题描述】:

我正在创建一个 SharePoint 功能,该功能将用于将某些内容类型(及其自定义列/字段)部署到新的 SharePoint 网站中。

我使用外部工具为内容类型 (Andrew Connell's custom STSADM commands) 生成 CAML,但是当我将它们放入功能并运行它时,我遇到了问题。

该功能按我预期的方式激活,但是当我尝试查看站点内容类型 (/_settings/mngctypes.aspx) 时,CPU 的使用率高达 100% (w3wp) 并保持在那里。

有没有人看到这个并知道如何解决它?

【问题讨论】:

  • 是的,部署是开发生命周期的一部分

标签: sharepoint


【解决方案1】:

我以前见过这个,生成的 XML 不包含 XML 命名空间: 另请注意,此工具不会创建 100% 正确用于功能的 XML。

错误的 XML:

<XmlDocument>
<FormTemplates xmlns="http://schemas.microsoft.com/sharepoint/v3/contenttype/forms">
<Display>ListForm</Display>
<Edit>ListForm</Edit>
<New>ListForm</New>
</FormTemplates>
</XmlDocument>

好-XML:

<XmlDocument NamespaceURI="http://schemas.microsoft.com/sharepoint/v3/contenttype/forms">
<FormTemplates xmlns="http://schemas.microsoft.com/sharepoint/v3/contenttype/forms">
<Display>ListForm</Display>
<Edit>ListForm</Edit>
<New>ListForm</New>
</FormTemplates>
</XmlDocument>

【讨论】:

  • 终于回到了这个问题上,你已经一针见血了!谢谢,救命!
  • 这也救了我。非常感谢!
【解决方案2】:

您所说的自定义列是指自定义字段吗?您要查看哪个内容类型页面?所有网站内容类型的列表,还是您的内容类型的详细信息页面?如果是后者,您的自定义列是否会导致错误?

【讨论】:

  • 有些人称它们为列,有些人称它们为字段:P。是的,问题出在查看内容类型页面时。添加了一些说明
猜你喜欢
  • 1970-01-01
  • 2011-04-12
  • 1970-01-01
  • 2012-05-22
  • 2020-10-08
  • 2013-05-02
  • 2020-03-03
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多