如何近乎实时地将数据推送到各种不同的客户端类型? [英] How to push data to variety of different client types in near real time?

查看:45
本文介绍了如何近乎实时地将数据推送到各种不同的客户端类型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们需要的是将体育数据推送到多种不同的客户端类型,例如 ajax/javascript、flash、.NET 和 Mac/iPhone.数据更新只需接近实时,几秒钟的延迟是可以接受的.

We need is to push sports data to a number of different client types such as ajax/javascript, flash, .NET and Mac/iPhone. Data updates need to only be near-real time with delays of several seconds being acceptable.

如何最好地做到这一点?

How to best accomplish this?

推荐答案

最好的解决方案(如果我们说的是 .NET)似乎是使用 WCF 和流式传输 http.客户端在端口 80 上与服务器建立第一个 http 连接,然后连接保持打开状态,并使用永不结束的流响应.(如果是,它会重新连接).

The best solution (if we're talking .NET) seem to be to use WCF and streaming http. The client makes the first http connection to the server at port 80, the connection is then kept open with a streaming response that never ends. (And if it does it reconnects).

以下是一个示例:流式 XML.

通过防火墙的解决方案:在 IIS 中保持连接打开

The solution to pushing through firewalls: Keeping connections open in IIS

这篇关于如何近乎实时地将数据推送到各种不同的客户端类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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