基于Websocket的消息实时推送设计与实现  被引量:14

Design and Implementation of Real- time Server Message Push Based on Websocket

在线阅读下载全文

作  者:齐华[1] 李佳[1] 刘军[2] 

机构地区:[1]西安工业大学电子信息工程学院,西安710000 [2]武警工程学院通信工程系,西安710086

出  处:《微处理机》2016年第3期36-39,43,共5页Microprocessors

基  金:陕西科学技术研究发展计划项目(2014K05-19)

摘  要:随着互联网技术的快速发展,基于B/S架构的实时通讯和消息推送的应用范围越来越广泛,服务器消息推送是很多应用中的一项重要功能,服务器推送技术的优劣直接影响着消息推送的效率。传统的解决方案有html refresh,定时轮询和comet,但这些实现方案存在着资源消耗大、执行效率低、服务器负担过大等缺陷。Html5中引入了websocket这一全双工通信协议,利用此技术实现的方案能够在减轻服务器负担的同时高效地对服务器消息进行实时推送。使用node.js平台和socket.io库技术设计并实现了一种基于websocket协议的服务器实时消息推送平台。运行测试结果显示能快速稳定地实现消息的实时服务器推送。With the rapid development of Internet technology,the application scope of the real- time communication and message push based on B / S framework is becoming more and more widely,and the server message push is one of the most important functions and the server push technology has a great influence on the efficiency of message pushing. The traditional solutions,such as html refresh,timing polling and comet,have disadvantages of resource wasting,low implementation efficiency and high server burden. Html 5,employing the websocket technology,as a full- duplex communication mechanism,is implemented to decrease server burden for the message push in real time. In this paper,the real- time message push system is designed and completed by the node. js platform and socket. io technology. The running test result shows that it can implement the real- time message server push rapidly and stably.

关 键 词:服务器推送 轮询 全双工协议 websocket协议 node.js技术 SOCKET io框架 

分 类 号:TP311.1[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象