diff --git a/lib/client/socket.js b/lib/client/socket.js index a338c2c3..cde35d27 100644 --- a/lib/client/socket.js +++ b/lib/client/socket.js @@ -17,7 +17,12 @@ var CloudCmd, Util, DOM, io; function connect() { socket = io.connect(CloudCmd.HOST, { - reconnect: true + 'reconnect' : true, + 'reconnection delay' : 500, + 'max reconnection attempts' : 1000000, + 'reconnect_failed' : function() { + Util.log('Could not reconnect. Reload page.'); + } }); CloudCmd.Socket = socket;