简体   繁体   English

实时更新图表/数据而无需设置间隔?

[英]Real time update for charts/data without setinterval?

I know its not a specific question but we have an criptocurrency exchange plataform and we would like to update data for users (ie. an table with current active sell orders) or a chart, actually we use setinterval, but I think its very heavy, and there's too many things to update every 1 second, there's an exchange (www.bittrex.com) that update those orders instantly and i really dont think they use setinterval. 我知道这不是一个特定的问题,但是我们有一个criptocurrency交换平台,并且我们想为用户更新数据(即具有当前有效卖单的表格)或图表,实际上我们使用setinterval,但是我认为它非常繁琐,而且有太多东西每1秒更新一次,有一个交易所(www.bittrex.com)立即更新这些订单,我真的不认为他们使用setinterval。 I know server-side cant send commands to user, but is there ANY way to tell user to update only when server have new data available? 我知道服务器端无法向用户发送命令,但是有什么方法可以告诉用户仅在服务器有新数据可用时进行更新吗?

Actually we use jquery, php and laravel. 实际上,我们使用jquery,php和laravel。

I'm asking this generic question because i tried to search on many ways on google and didn't found any start way. 我问这个一般性的问题,因为我尝试在Google上进行多种搜索,但未找到任何开始方式。

You can use Socket.Io for realtime update. 您可以使用Socket.Io进行实时更新。 visit http://socket.io for more information 访问http://socket.io了解更多信息

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM