是的HttpListener类去precated?是的、HttpListener、precated

由网友(我年轻我任性)分享简介:我试图用设置Web服务,而无需使用IIS。I am trying with setting a web service without using IIS.我知道我们可以使用的HttpListener之前创建简单的HTTP服务器。我想知道如果现在是pcated德$ P $因为WCF似乎提供了更先进的功能。I kn...

我试图用设置Web服务,而无需使用IIS。

I am trying with setting a web service without using IIS.

我知道我们可以使用的HttpListener之前创建简单的HTTP服务器。我想知道如果现在是pcated德$ P $因为WCF似乎提供了更先进的功能。

I knew we can use HttpListener to create simple http server before. I am wondering if it is deprecated now since WCF seems provide more advanced features.

推荐答案

微软建议不要使用它。我与WCF去,如果你需要知道这将是维护好几年。

Microsoft recommend against using it. I'd go with WCF if you need to know it'll be maintainable for some years.

另外,如果你很高兴暴露RESTful服务而不是SOAP或XML-RPC,有几个独立的.NET程序集,你可以用它来承载你的应用程序的HTTP服务器,而不在IIS或WCF任何依赖性 - 它们'LL单下运行,也没有问题:

Alternatively, if you're happy to expose RESTful services rather than SOAP or XML-RPC, there are a few standalone .NET assemblies you can use to host an HTTP server in your app without any dependency on IIS or WCF - they'll run under Mono, too, with no problems:

皮划艇 - https://github.com/kayak/kayak 萤火虫 - http://loudej.github.com/firefly/

Kayak - https://github.com/kayak/kayak Firefly - http://loudej.github.com/firefly/

我们用它们来确保我们有完全控制服务器堆栈,并能的黑盒子是.NET的HTTP侦听器的参数之外调整的事情。

We use them to make sure we have complete control over the server stack, and can tweak things outside the parameters of the black-boxes that are .NET's HTTP listeners.

阅读全文

相关推荐

最新文章