node.js - 前端websocket连接提示502 Bad GateWay
伊谢尔伦
伊谢尔伦 2017-04-17 11:11:30
0
2
672

在前端用websocket连接时提示说502 Bad GateWay,过了一会又自己连上了,这样体验很差啊。。。请问是什么原因呢?另外,前台关闭页面时,后台服务器没有即使获取disconnect事件。。。以上两个问题在本地测试时完全没问题。。后台用的是nodejs,(socket模块:socket.io)求教是怎么回事?!和解决办法~~

伊谢尔伦
伊谢尔伦

小伙看你根骨奇佳,潜力无限,来学PHP伐。

reply all(2)
Peter_Zhu

Search nginx websocket or nginx socket.io yourself

Don’t step on it

Ty80

It should be a background program error...
I encountered a problem before. The background fetched data from the database. Because some fields had HTML and entities, and some did not, it caused a network request to the server 502. Later, I was able to basically conclude that 502 was a program problem...

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template