长轮询真的比定期 ajax 轮询更好吗?
长轮询的开销是建立 http 连接,而且在服务器端,Java EE 服务器必须保存大量挂起的请求。
对于间隔为 10/20 秒的定期轮询,它会比长轮询效果更差吗?
The overhead for long polling is http connection establishment, also on server side the Java EE server has to hold a lot of suspended requests.
For periodic polls with 10/20 seconds interval, it will work worse than long polling?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这取决于多种因素:
(毫无疑问还有其他应用程序......)
It depends on various things:
(And no doubt there are others...)