需先部署mosquitto服务器,并配置mqtt服务器支持websocket,参见http://rensanning.iteye.com/blog/2407142