通过 SharePoint 功能部署内容类型时 CPU 使用率高 [英] High CPU usage when deploying content types via a SharePoint feature

查看:90
本文介绍了通过 SharePoint 功能部署内容类型时 CPU 使用率高的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

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

I'm creating a SharePoint feature which will be used to deploy some content types (and their custom columns/ fields) into a a new SharePoint site.

我使用外部工具为内容类型生成 CAML (AndrewConnell 的自定义 STSADM 命令),但是当我将它们放入该功能并运行它时,我遇到了问题.

I've used an external tool to generate the CAML for the content types (Andrew Connell's custom STSADM commands) but when I put them into the feature and run it I hit a problem.

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

The feature activates like I expect, but when I try and view the Site Content Types (/_settings/mngctypes.aspx) the CPU shoots up to 100% usage (w3wp) and stays there.

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

Has anyone seen this and know how to resolve it?

推荐答案

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

I've seen this before, the XML generated does not contain the XML Namespace: Also note that this tool doesn't create XML that is 100% correct for use in a Feature.

错误的 XML:

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

Good-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>

这篇关于通过 SharePoint 功能部署内容类型时 CPU 使用率高的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆