WCF 服务而不是 ASMX Web 服务?

发布于 2024-09-01 20:23:23 字数 536 浏览 4 评论 0原文

我正在编写一个 SOAP 服务器,它将充当外部客户端的端点。外部客户端需要 SOAP 1.1。我将在 SOAP 消息中嵌入业务对象,并将它们传递给内部应用程序,获取响应并用 SOAP 消息响应永恒的客户端。

几年前我做了基于 ASMX 的传统 Web 服务。现在,我一直在探索 WCF 服务并想知道采取的最佳方法。

1) WCF 是否应该被视为 ASMX Web 服务的超集?

2) 是否有任何理由仍然使用 ASMX 而不是 WCF 来编写新的 Web 服务?

3) 与 SOAP 扩展相比,WCF 是否提供了更好的工具来处理 SOAP 消息?

4) 我是否可以使用 WCF 限制与 SOAP 1.1 的通信,就像在 ASMX 中更改 web.config 一样?

5) WCF 是否有一种简单的方法来记录或查看访问服务的请求,而无需求助于 SOAP 扩展之类的东西?

抱歉,我的问题不是很具体;仍在尝试了解我需要知道的内容...

使用 VS2008、Windows Server

2008。Chris

I'm writing a SOAP Server that will act as an endpoint for an external client. The external client expects SOAP 1.1. I'll be taking embedded business objects in the SOAP messages and passing them to an internal application, getting responses back and responding with SOAP messages to the eternal client.

I did the traditional ASMX based web services several years ago. Now, I've been exploring WCF Services and wondering the best approach to take.

1) Should WCF be considered a superset of ASMX web services?

2) Is there any reason to still write new web services using ASMX instead of WCF?

3) Does WCF provide better facilities for working with SOAP messages, as opposed to SOAP Extensions?

4) Can I restrict communication to SOAP 1.1 using WCF, the way I can with a web.config change in ASMX?

5) Does WCF have an easy way to log or review the requests that hit the service without resorting to something like SOAP extensions?

Sorry my questions are not very specific; still trying to get handle on what I need to know...

Using VS2008, Windows Server 2008.

Chris

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

心的憧憬 2024-09-08 20:23:23

我建议您使用 WCF。如果将 WCF 服务配置为使用 basichttpbinding,它将作为 SOAP 1.1 服务工作。

  1. WCF“取代”了多种通信技术,包括 asmx。
  2. 我想不出任何技术原因。如果您的团队了解asmx但不了解wcf,或者您的项目有大量asmx服务并且您不想引入新技术,那么您可以这样做。
  3. WCF 有消息契约,但不能 100% 确定您的意思。
  4. 是的,基本 http 绑定
  5. 是的,您可以使用 WCF 跟踪

I would recommend that you use WCF. If you configure your WCF service to use basichttpbinding, it will work as a SOAP 1.1 service.

  1. WCF "replaces" several communication technologies, including asmx.
  2. I cannot think of any technical reason. You may do it if you have a team that knows asmx but not wcf, or you have a project with a lot of asmx services and you do not want to introduce a new technology.
  3. WCF has message contracts, but not 100% sure what you mean here.
  4. Yes, basic http binding
  5. Yes, you can use WCF tracing
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文