socket.io seems to be delayed on my Android phone

妖精的绣舞 提交于 2019-12-04 13:29:02

I will answer my own question...

I tried both websockets with even only server-to-client communication and server-sent events on my mobile phones (Nexus 5 with Lollipop 5.1 and an old LG p930 with Gingerbread 2.3.5) and none of them works fine with these technos. The communication is broken after 5 ... 10 or 60 seconds but it always breaks.

I will use AJAX with repetitive queries. With a query at each 0.5 sec, I never lost the communication. It will be enough for my current project.

But I would have appreciated to see SSE and/or websockets working on Chrome 45/Android 5.1.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!