deepstream.io宣布发布deepstream2.0,一个百万级数据同步和消息传递的引擎。服务器和客户端基于WebSockets协议通讯。提供多种语言的客户端开发包,包括可直接在浏览器使用的JavaScript包。
deepstream的使用场景:
协作应用,例如GoogleDocs或者Trello之类
快速贸易、拍卖平台
消息传递和社交交互平台
金融报表和风险控制
赌场或者是多玩家的手机游戏
实习的统计分析和监控系统
物联网数据采集和控制系统
股票和库存控制
过程管理系统
其声称基准测试比Socket.IO快出1000倍!https://deepstream.io/blog/deepstream-2.0-more-tha-1000-times-faster-tha-socket.io/
示例代码:
// get the recordvar driver = cliet.record.getRecord( 'driver/14' );// subscribe to ay chages withi positiodriver.subscribe( 'positio', fuctio( positio ){ updateMarker( positio.x, positio.y );});Adroid代码:
// implemets adroid.locatio.LocatioListeerpublic void oLocatioChaged(Locatio locatio) { // get the record Record record = cliet.record.getRecord( "driver/14" ); // ay kid of data path works record.set( "positio.x", locatio.getLogitude() ); //as well as ay kid of serializable datatype record.set( "positio.y", locatio.getLatitude() );}
评论