为什么 IIS7 中的 net.tcp 在共享托管环境中会出现问题?

发布于 2024-11-02 03:34:45 字数 305 浏览 1 评论 0 原文

我尝试使用推送模型编写一个聊天应用程序,但到目前为止,我仅在具有自托管 wcf 服务(使用双工 net.tcp)的 Intranet 环境中这样做。现在我想把这个服务器放在IIS7中上线。我已经咨询了一些托管提供商,但他们都回复了这样的话:“不,我们没有激活 net.tcp,我们可能永远不会激活它”。为什么他们如此不愿意这样做?看来我必须拥有自己的虚拟服务器?但是,我在 IIS7 中使用 net.tcp 面临哪些风险?我还有什么其他选择?我已经检查了“WebSockets”,但它似乎还没有准备好,我不确定它是否是我的情况的解决方案。我不是在编写 HTML5 聊天,而是在桌面上编写窗口聊天。

Im trying to write a chat app with the push-model but up to now I have only done so in a intranet-environment with a self-hosted wcf-service (using duplex net.tcp). Now I want to place this server online in IIS7. I have checked with a number of hosting providers but all have replied with something like: "No we dont have net.tcp activated and we probably never will activate it". Why are they so reluctant in doing so? It seems I have to get my own virtual server? But what risks am I facing using net.tcp for IIS7? What other options do I have? I have checked out "WebSockets" but it doesnt seem to be ready yet and Im not sure if its a solution in my case. Im not writing a HTML5-chat but a windowed chat for the desktop.

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

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

发布评论

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

评论(2

故事未完 2024-11-09 03:34:45

嗯,有一些潜在的问题

  1. 通过打开新端口,防火墙需要进行调整。
  2. 通过侦听 TCP,应用程序的攻击面增加了。
  3. 每个客户都必须受到管理,这样他们就不会尝试使用相同的端口号。
  4. TCP 要求连接保持打开状态,这会增加服务器的负载。
  5. 如果机器位于 NAT 后面,这也会使事情变得复杂

请注意,您可以使用 HTTP 进行双工通信,使用 WSDualHttpBinding

Well there are a few potential problems

  1. By opening a new port the firewalls will need adjusted.
  2. By listening on TCP the attack surface of your application has increased.
  3. Each customer would have to be managed so they don't try to take the same port number.
  4. TCP requires connections to stay open, increasing load on the server.
  5. If machines are behind a NAT that complicates things too

Note that you can use HTTP for duplex communications, using WSDualHttpBinding

り繁华旳梦境 2024-11-09 03:34:45

我认为不支持 Net.TCP 的主要原因是 IIS 6.0缺乏对非 HTTP 协议的支持,例如 Net。 TCP命名管道MSMQ点对点。非 HTTP 协议需要使用 Windows Process Activation Services (WAS),这是在大多数共享托管提供商的舒适区之外。它是 IIS 7.0 及更高版本的组成部分,但 WAS 仍然是从提供商的技术角度来看,这是相当新的——他们仍然需要接受教育。希望时间和可能增加的需求(随着技术的吸收)能够解决这个问题。

I believe the main reason for not supporting Net.TCP is due to the fact that IIS 6.0 lacks support for non-HTTP protocols such as Net.TCP, named pipes, MSMQ or Peer-to-Peer. Non-HTTP protocols require using Windows Process Activation Services (WAS) which is outside the comfort zone of most shared hosting providers. It is an integral part of IIS 7.0 and onwards, but WAS is still rather new from the provider's technological point of view - they still need to be educated. Hopefully, time and possibly increased demand (as the technology is assimilated) will take care of that.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文