是“长轮询”创建Web实时应用程序的最有效方法? [英] Is "long polling" the most efficient way to create a Web Real Time App?
问题描述
我想创建一个这样的应用程序:
创建这个实时应用程序的最有效方法是什么?
闪光?长期投票? HTTP流媒体?或者别的什么东西?
谢谢;) 现在,长时间的投票可能是最好的解决方案。许多大牌网站都有长时间的投票实施,包括Facebook,Google和eBay。并非每个人都在其浏览器中安装/启用了Flash。将来 Web Sockets 可能能够为我们做一个更容易的工作。
更新:在撰写本文时,。还有Opera的可供下载的公共快照构建与API的实现。这意味着测试API是广泛可用的。有关详情,请参阅此答案。
I want to create an application like this:
What is the most efficient way to create this real time application?
Flash? Long polling? Http Streaming? or something else?
Thanks ;)
For now, long polling is probably the best solution. Many big-name sites have long polling implementations, including Facebook, Google and eBay. Not everyone has Flash installed/enabled in their browsers. In the future Web Sockets might be able to do an easier job of it for us.
Update: As of this writing, the WebSocket API is implemented in the latest WebKit (Chrome/Safari) and Firefox 4 beta. There is also a public snapshot build of Opera available for download with an implementation of the API. This means testing the API is widely available. For more information, see this answer.
这篇关于是“长轮询”创建Web实时应用程序的最有效方法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!