.NET远程与Web服务与Windows通讯基础(WCF) [英] .NET Remoting vs. Web Services vs. Windows Communication Foundation (WCF)

查看:159
本文介绍了.NET远程与Web服务与Windows通讯基础(WCF)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

任何人都愿意帮助我与.NET远程优点/缺点,Web服务和WCF?我曾有点与.NET远程和Web服务,我架构一个新的ASP.NET 3.5 Web应用程序,我将使用一个SQL 2008数据库。主要是我想知道,如果它是值得的真正考虑WCF为这个应用程序。

Anyone willing to help me out with pros/cons on .NET Remoting, Web Services, and WCF? I have worked a bit with .NET Remoting and Web Services and I am architecting a new ASP.NET 3.5 web app where I will be using a SQL 2008 DB. Primarily I am wondering if it would be worthwhile to really look into WCF for this app.

在此特定情况下,这里有一些相关的要点:

In this particular instance, here are some relevant points:


  • 最持久数据将是错误和使用情况跟踪。

  • 即使我去与.NET远程处理,流量将无法保证物理远程服务器,但我想梦想,它有一天会!

  • 在这个时候,我没有预见到需要抢从其他Web应用程序此数据。

不过,我还是想知道:


  • 当/你为什么会在Web应用程序中使用.NET远程处理?

  • 当/你为什么要使用Web服务在网络应用?

  • 当/为什么你会在web应用程序使用WCF?

  • 我应该考虑技术,如LINQ to SQL的?

  • 是否有其他更好的选择是那里?

推荐答案

其实,我打开我们的软件从传统的.NET远程到WCF。在通信,从远程发生膨胀是惊人的(只是看一个Wireshark的跟踪)。移动到WCF之前,我想过只用传统的.NET Web服务,但我们的形式实现我们的远程调用接口将需要的修饰(我们曾经使用的一些out和ref参数,如果我不是一个Asp.Net Web服务不能做哪些误)。

I actually switched our software from traditional .NET Remoting to WCF. The bloat in communication that occurred from Remoting was amazing (just look at a wireshark trace). Before moving to WCF i thought about using just a traditional .NET webservice, but the interfaces we implimented for our remoting calls would require to much modification (We had used some out and ref parameters which an Asp.Net webservice cant do if I am not mistaken).

真的,我想不出一个理由去与一个Asp.Net web服务,但我不是一个Asp.Net的家伙。对我来说,在WCF没有优势。它可能会更容易去与Web服务,而WCF提供的灵活性是我所需要的。特别是在消息格式化的区域。

Really, I cant think of a reason to go with an Asp.Net webservice, but Im not an Asp.Net guy. To me, it offers no advantages over WCF. It may be easier to go with a webservice, but the flexibility WCF offered was what I needed. Especially in the area of message formatting.

我喜欢我的WCF服务,因为一个服务,我可以充当了JSON或SOAP / XML,所有的协议都支持(IPC,TCP和HTTP)。

I like my WCF service because with one service I can either serve up JSON or SOAP/XML and all the protocols are supported (ipc, tcp, and http).

与WCF的令人失望的是,它的严格要求绑定你定义一个端点HTTP和HTTPS,如果你想在一个基于Web的场景中使用它。不像只是作品一个传统的web服务,无论是否其安全与否。

The bummer with WCF is that its strict bindings require you to define an endpoint for both HTTP and HTTPS if you wish to use it in a web based scenario. Unlike a traditional Webservice which "just works" regardless if its secure or not.

这篇关于.NET远程与Web服务与Windows通讯基础(WCF)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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