简体   繁体   English

SharePoint 2010的自定义Wcf服务应放在哪里?

[英]Where should custom Wcf service for SharePoint 2010 resides?

I want to create Wcf service for SharePoint 2010. I strictly want to use server object model. 我想为SharePoint 2010创建Wcf服务。我严格希望使用服务器对象模型。 I have gone through two articles http://www.dotnetcurry.com/ShowArticle.aspx?ID=760 我浏览了两篇文章http://www.dotnetcurry.com/ShowArticle.aspx?ID=760

http://nikspatel.wordpress.com/2012/02/29/step-by-step-building-custom-wcf-services-hosted-in-sharepoint-part-i/ http://nikspatel.wordpress.com/2012/02/29/step-by-step-building-custom-wcf-services-hosted-in-sharepoint-part-i/

I want to know if we are using sharepoint 2010 server object model then is it mandatory that custom wcf must reside on the same machine on which sharepoint is installed (as decribed in second link) ? 我想知道我们是否正在使用sharepoint 2010服务器对象模型,那么是否必须将自定义wcf驻留在安装了Sharepoint的同一台计算机上(如第二个链接中所述)?

I think, thows articles sre different. 我认为,搜罗文章有很大不同。

Second one described how to host your wcf service "inside" share point env., when the first one describe communication between them. 当第一个描述它们之间的通信时,第二个描述了如何在内部共享点环境中托管wcf服务。

For first model - it is nothing more then some wcf service, calling some SharePoint api (server model?). 对于第一个模型-就是一些wcf服务,它调用了一些SharePoint api(服务器模型?)。 Inthis case - they can be hosted in different machines as well. 在这种情况下,它们也可以托管在不同的计算机中。

If you want to use the server object model you have to host your WCF service on the same server as your SharePoint is installed on. 如果要使用服务器对象模型,则必须将WCF服务托管在安装了SharePoint的服务器上。

If the WCF service has to be on a different server you can use the client object model or the SharePoint webservices to communicate to SharePoint. 如果WCF服务必须位于其他服务器上,则可以使用客户端对象模型或SharePoint Web服务与SharePoint通信。

(link to a question about using server object model on different server (链接到有关在不同服务器上使用服务器对象模型的问题

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM