diff --git a/services/web/frontend/js/ide/connection/ConnectionManager.js b/services/web/frontend/js/ide/connection/ConnectionManager.js index 74ac7acf8d..957a534e77 100644 --- a/services/web/frontend/js/ide/connection/ConnectionManager.js +++ b/services/web/frontend/js/ide/connection/ConnectionManager.js @@ -150,7 +150,11 @@ export default ConnectionManager = (function () { window.wsRetryHandshake && connectionAttempt++ < window.wsRetryHandshake ) { - return setTimeout(() => this.ide.socket.socket.connect(), 100) + return setTimeout( + () => this.ide.socket.socket.connect(), + // add jitter to spread reconnects + connectionAttempt * (1 + Math.random()) * 1000 + ) } this.updateConnectionManagerState('error') sl_console.log('socket.io error', err)